From 7ac909566f98af31da3c562f4aa15197e9680b6e Mon Sep 17 00:00:00 2001 From: cytopia Date: Tue, 29 Jan 2019 12:50:45 +0100 Subject: [PATCH] Refs #451 Improve docs about docker-compose.override.yml --- .../docker-compose-override-yml.rst | 18 ++++++++++++++++++ docs/custom-container/enable-all-container.rst | 2 ++ docs/custom-container/enable-blackfire.rst | 1 + docs/custom-container/enable-mailhog.rst | 1 + docs/custom-container/enable-rabbitmq.rst | 1 + docs/custom-container/enable-solr.rst | 1 + 6 files changed, 24 insertions(+) diff --git a/docs/configuration-files/docker-compose-override-yml.rst b/docs/configuration-files/docker-compose-override-yml.rst index 57b1112b..171ddd6b 100644 --- a/docs/configuration-files/docker-compose-override-yml.rst +++ b/docs/configuration-files/docker-compose-override-yml.rst @@ -16,6 +16,24 @@ By default, this file does not exist and you must create it. You can either copy .. contents:: :local: +.. _docker_compose_override_yml_how_does_it_work: + +How does docker-compose.override.yml work? +========================================== + +When you run ``docker-compose up``, it searches for a file named ``docker-compose.yml`` and reads +all configured services, networks, volumes etc to create your Docker stack. If you also +additionally have a file named ``docker-compose.override.yml`` this will be read as well and used +as an override file to complement. It works in the following order: + +1. All definitions from ``docker-compose.yml`` will be used +2. All definitions that are also defined in ``docker-compose.override.yml`` will automatically + overwrite the settings from ``docker-compose.yml`` +3. All definitions only available in ``docker-compose.override.yml`` will be added additionally. + +For starting up your Docker Compose stack there are no additional steps or command line arguments +required. If both files exist, they will be read automatically. + .. seealso:: |ext_lnk_docker_compose_extends| diff --git a/docs/custom-container/enable-all-container.rst b/docs/custom-container/enable-all-container.rst index bd06f250..65ac6141 100644 --- a/docs/custom-container/enable-all-container.rst +++ b/docs/custom-container/enable-all-container.rst @@ -9,6 +9,8 @@ Enable all additional container Besides providing basic LAMP/MEAN stack container, which are well integrated into the Devilbox intranet, the Devilbox also ships additional pre-configured container that can easily be enabled. +.. seealso:: :ref:`docker_compose_override_yml_how_does_it_work` + **Table of Contents** diff --git a/docs/custom-container/enable-blackfire.rst b/docs/custom-container/enable-blackfire.rst index 13065050..b9810cc0 100644 --- a/docs/custom-container/enable-blackfire.rst +++ b/docs/custom-container/enable-blackfire.rst @@ -12,6 +12,7 @@ This section will guide you through getting Blackfire integrated into the Devilb * |ext_lnk_blackfire_github| * |ext_lnk_blackfire_dockerhub| * :ref:`custom_container_enable_all_additional_container` + * :ref:`docker_compose_override_yml_how_does_it_work` **Table of Contents** diff --git a/docs/custom-container/enable-mailhog.rst b/docs/custom-container/enable-mailhog.rst index e320120f..1d0436c3 100644 --- a/docs/custom-container/enable-mailhog.rst +++ b/docs/custom-container/enable-mailhog.rst @@ -12,6 +12,7 @@ This section will guide you through getting MailHog integrated into the Devilbox * |ext_lnk_mailhog_github| * |ext_lnk_mailhog_dockerhub| * :ref:`custom_container_enable_all_additional_container` + * :ref:`docker_compose_override_yml_how_does_it_work` **Table of Contents** diff --git a/docs/custom-container/enable-rabbitmq.rst b/docs/custom-container/enable-rabbitmq.rst index 1df3ff8c..9d803fd2 100644 --- a/docs/custom-container/enable-rabbitmq.rst +++ b/docs/custom-container/enable-rabbitmq.rst @@ -12,6 +12,7 @@ This section will guide you through getting RabbitMQ integrated into the Devilbo * |ext_lnk_rabbitmq_github| * |ext_lnk_rabbitmq_dockerhub| * :ref:`custom_container_enable_all_additional_container` + * :ref:`docker_compose_override_yml_how_does_it_work` **Table of Contents** diff --git a/docs/custom-container/enable-solr.rst b/docs/custom-container/enable-solr.rst index d03e2a11..bbd2bc44 100644 --- a/docs/custom-container/enable-solr.rst +++ b/docs/custom-container/enable-solr.rst @@ -12,6 +12,7 @@ This section will guide you through getting Solr integrated into the Devilbox. * |ext_lnk_solr_github| * |ext_lnk_solr_dockerhub| * :ref:`custom_container_enable_all_additional_container` + * :ref:`docker_compose_override_yml_how_does_it_work` **Table of Contents**