From 7d371cc66dc2d9495fc8df7f517627db16b62c12 Mon Sep 17 00:00:00 2001 From: cytopia Date: Sat, 2 Mar 2019 20:40:45 +0100 Subject: [PATCH] Documentation: Add IMPORTANT section --- docs/getting-started/important.rst | 59 +++++++++++++++++++ docs/getting-started/install-the-devilbox.rst | 2 + docs/getting-started/prerequisites.rst | 2 + docs/index.rst | 1 + 4 files changed, 64 insertions(+) create mode 100644 docs/getting-started/important.rst diff --git a/docs/getting-started/important.rst b/docs/getting-started/important.rst new file mode 100644 index 00000000..53455f6a --- /dev/null +++ b/docs/getting-started/important.rst @@ -0,0 +1,59 @@ +********* +IMPORTANT +********* + +The following is a collection of important **do's and don'ts** you should be aware of when starting +to use the Devilbox and Docker in general. + +**Table of Contents** + +.. contents:: :local: + + +Starting +======== + +Do not run via ``sudo`` or ``root`` +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +Do not start the Devilbox with ``sudo`` or as ``root`` user. If it complains about permissions when +starting it with your normal system user, it is probably due to the fact, that your user is not in +the ``docker`` group. + +.. seealso:: **Ensure you have read and done the following:** + + * Add user to ``docker`` group: :ref:`prerequisites_docker_installation` + * Synronize file permissions: :ref:`install_the_devilbox_set_uid_and_gid` + +.. warning:: If you start the Devilbox with ``sudo`` or as ``root`` user, it will most likely mess with your file permissions. + + +Starting, Stopping and Restarting +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +Whenever you want to stop the Devilbox, change configuration and start up again, do not forget to +remove stopped container. + +.. code-block:: bash + + # Stop the Devilbox + host> docker-compose stop + + # Remove stopped container + host> docker-compose rm + + # Start the Devilbox + host> docker-compose up + +.. seealso:: :ref:`start_the_devilbox_stop_and_restart` (why do ``docker-compose rm``?) + + +Backups +======= + +Ensure to do regular database backups! Better safe then sorry! + +.. seealso:: + * :ref:`backup_and_restore_mysql` + * :ref:`backup_and_restore_pgsql` + * :ref:`backup_and_restore_mongo` diff --git a/docs/getting-started/install-the-devilbox.rst b/docs/getting-started/install-the-devilbox.rst index d3c52822..4b5963d2 100644 --- a/docs/getting-started/install-the-devilbox.rst +++ b/docs/getting-started/install-the-devilbox.rst @@ -52,6 +52,8 @@ of settings (such as which version to start up). * :ref:`env_file` +.. _install_the_devilbox_set_uid_and_gid: + Set uid and gid =============== diff --git a/docs/getting-started/prerequisites.rst b/docs/getting-started/prerequisites.rst index e8a12480..3a21a7c7 100644 --- a/docs/getting-started/prerequisites.rst +++ b/docs/getting-started/prerequisites.rst @@ -66,6 +66,8 @@ Additionally you will require ``git`` in order to clone the devilbox project. * :ref:`howto_find_docker_and_docker_compose_version` +.. _prerequisites_docker_installation: + Docker installation =================== diff --git a/docs/index.rst b/docs/index.rst index 1cc34045..135e9af5 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -50,6 +50,7 @@ host is ready to be served with your custom domain. getting-started/create-your-first-project getting-started/enter-the-php-container getting-started/change-container-versions + getting-started/important .. toctree::