From 12447e42ff05b2fbbe1cecafb7f636c15a24a9a8 Mon Sep 17 00:00:00 2001 From: kaiyou Date: Mon, 6 Nov 2017 11:41:32 +0100 Subject: [PATCH] Generate dynamic download links for the configuration (cherry picked from commit 881fae382a63373eb4dab6dc5111b3e7f6f133c4) --- docs/compose/{.env.dist => .env} | 0 ...er-compose.yml.dist => docker-compose.yml} | 9 ------ docs/compose/setup.rst | 29 ++++++++----------- 3 files changed, 12 insertions(+), 26 deletions(-) rename docs/compose/{.env.dist => .env} (100%) rename docs/compose/{docker-compose.yml.dist => docker-compose.yml} (91%) diff --git a/docs/compose/.env.dist b/docs/compose/.env similarity index 100% rename from docs/compose/.env.dist rename to docs/compose/.env diff --git a/docs/compose/docker-compose.yml.dist b/docs/compose/docker-compose.yml similarity index 91% rename from docs/compose/docker-compose.yml.dist rename to docs/compose/docker-compose.yml index c0291070..0900e5b5 100644 --- a/docs/compose/docker-compose.yml.dist +++ b/docs/compose/docker-compose.yml @@ -3,7 +3,6 @@ version: '2' services: front: - # build: nginx image: mailu/nginx:$VERSION restart: always env_file: .env @@ -36,7 +35,6 @@ services: - "$ROOT/redis:/data" imap: - # build: dovecot image: mailu/dovecot:$VERSION restart: always env_file: .env @@ -46,7 +44,6 @@ services: - "$ROOT/overrides:/overrides" smtp: - # build: postfix image: mailu/postfix:$VERSION restart: always env_file: .env @@ -55,7 +52,6 @@ services: - "$ROOT/overrides:/overrides" antispam: - # build: rspamd image: mailu/rspamd:$VERSION restart: always env_file: .env @@ -64,7 +60,6 @@ services: - "$ROOT/overrides/rspamd:/etc/rspamd/override.d" antivirus: - # build: clamav image: mailu/$ANTIVIRUS:$VERSION restart: always env_file: .env @@ -72,7 +67,6 @@ services: - "$ROOT/filter:/data" webdav: - # build: $WEBDAV image: mailu/$WEBDAV:$VERSION restart: always env_file: .env @@ -80,7 +74,6 @@ services: - "$ROOT/dav:/data" admin: - # build: admin image: mailu/admin:$VERSION restart: always env_file: .env @@ -90,7 +83,6 @@ services: - /var/run/docker.sock:/var/run/docker.sock:ro webmail: - # build: "$WEBMAIL" image: "mailu/$WEBMAIL:$VERSION" restart: always env_file: .env @@ -98,7 +90,6 @@ services: - "$ROOT/webmail:/data" fetchmail: - # build: fetchmail image: mailu/fetchmail:$VERSION restart: always env_file: .env diff --git a/docs/compose/setup.rst b/docs/compose/setup.rst index c5ed4529..263ebe51 100644 --- a/docs/compose/setup.rst +++ b/docs/compose/setup.rst @@ -15,21 +15,16 @@ Mailu will store all of its persistent data in a path of your choice Download the initial configuration file --------------------------------------- -Docker Compose configuration is stored in a file named ``docker-compose.yml``. -Additionally, Mailu relies on an environment file for various settings. -Download the proper template files from the git repository. For `stable`: +Docker Compose configuration is stored in a file named +:download:`docker-compose.yml`. Additionally, Mailu +relies on a :download:`.env` file for various settings. Download +the proper template files from the git repository. To download the configuration +for the "|version|" branch, use: -.. code-block:: bash +.. parsed-literal:: - wget -O docker-compose.yml https://raw.githubusercontent.com/Mailu/Mailu/stable/docs/compose/docker-compose.yml.dist - wget -O .env https://raw.githubusercontent.com/Mailu/Mailu/stable/docs/compose/.env.dist - -For the latest version (replace with version number otherwise): - -.. code-block:: bash - - wget -O docker-compose.yml https://raw.githubusercontent.com/Mailu/Mailu/master/docs/compose/docker-compose.yml.dist - wget -O .env https://raw.githubusercontent.com/Mailu/Mailu/master/docs/compose/.env.dist + wget https://mailu.io/|version|/_downloads/docker-compose.yml + wget https://mailu.io/|version|/_downloads/.env Then open the ``.env`` file to setup the mail server. Modify the ``ROOT`` setting to match your setup directory if different from ``/mailu``. @@ -50,11 +45,11 @@ you would simply like the server to listen on all interfaces, use ``0.0.0.0``. Modify ``BIND_ADDRESS6`` to match the public IPv6 address assigned to your server. The behavior is identical to ``BIND_ADDRESS4``. -Set the `TLS_FLAVOR` to one of the following +Set the ``TLS_FLAVOR`` to one of the following values: -- `cert` is the default and requires certificates to be setup manually; -- `letsencrypt` will use the Letsencrypt! CA to generate automatic ceriticates; -- `notls` will disable TLS, this is not recommended except for testing. +- ``cert`` is the default and requires certificates to be setup manually; +- ``letsencrypt`` will use the Letsencrypt! CA to generate automatic ceriticates; +- ``notls`` will disable TLS, this is not recommended except for testing. Enable optional features ------------------------