From e8dee22ecfc8836f7d0a9ec56b3d68fba582b718 Mon Sep 17 00:00:00 2001 From: Ionut Filip Date: Tue, 16 Oct 2018 16:12:42 +0300 Subject: [PATCH] Added vars and fixed naming use --- setup/flavors/compose/docker-compose.yml | 10 ++-- setup/flavors/compose/mailu.env | 32 +++++++++++-- setup/templates/steps/initial-config.html | 58 +++++++++++++++++++++++ setup/templates/steps/root.html | 8 ---- setup/templates/steps/services.html | 15 ++++-- setup/templates/wizard.html | 4 +- 6 files changed, 105 insertions(+), 22 deletions(-) create mode 100644 setup/templates/steps/initial-config.html delete mode 100644 setup/templates/steps/root.html diff --git a/setup/flavors/compose/docker-compose.yml b/setup/flavors/compose/docker-compose.yml index 3dcfa5a2..bf6c2db8 100644 --- a/setup/flavors/compose/docker-compose.yml +++ b/setup/flavors/compose/docker-compose.yml @@ -71,7 +71,7 @@ services: - front # Optional services - {% if enable_antispam %} + {% if antispam_enabled %} antispam: image: mailu/rspamd:{{ version }} restart: always @@ -84,7 +84,7 @@ services: - front {% endif %} - {% if enable_antivirus %} + {% if antivirus_enabled %} antivirus: image: mailu/clamav:{{ version }} restart: always @@ -93,9 +93,9 @@ services: - "{{ root }}/filter:/data" {% endif %} - {% if enable_webdav %} + {% if webdav_enabled %} webdav: - image: mailu/radivale:{{ version }} + image: mailu/radicale:{{ version }} restart: always env_file: {{ env }} volumes: @@ -112,7 +112,7 @@ services: {% endif %} # Webmail - {% if enable_webmail %} + {% if webmail_enabled %} webmail: image: mailu/{{ webmail }}:{{ version }} restart: always diff --git a/setup/flavors/compose/mailu.env b/setup/flavors/compose/mailu.env index 1512e75b..4f470533 100644 --- a/setup/flavors/compose/mailu.env +++ b/setup/flavors/compose/mailu.env @@ -10,7 +10,7 @@ # Set this to the path where Mailu data and configuration is stored # This variable is now set directly in `docker-compose.yml by the setup utility -# ROOT= {{ root }} +# ROOT={{ root }} # Set to a randomly generated 16 bytes string SECRET_KEY={{ secret(16) }} @@ -20,8 +20,14 @@ SECRET_KEY={{ secret(16) }} # PUBLIC_IPV4= {{ bind4 }} (default: 127.0.0.1) # PUBLIC_IPV6= {{ bind6 }} (default: ::1) +# Main mail domain +# DOMAIN={{ domain }} + # Mail address of the postmaster -POSTMASTER={{ postmaster }} +POSTMASTER={{ postmaster or 'admin'}} + +#Chose how secure connections will behave: +#TLS_FLAVOR={{ tls_flavor }} # Hostnames for this server, separated with comas HOSTNAMES={{ hostnames }} @@ -30,7 +36,27 @@ HOSTNAMES={{ hostnames }} AUTH_RATELIMIT={{ auth_ratelimit }} # Opt-out of statistics, replace with "True" to opt out -DISABLE_STATISTICS={{ disable_statistics }} +DISABLE_STATISTICS={{ disable_statistics or 'False' }} + +################################### +# Optional features +################################### + +#Expose the admin interface +ADMIN={{ admin_enabled or 'false' }} + +#Chose which webmail to run if any +#WEBMAIL_ENABLED={{ webmail_enabled or 'false' }} +WEBMAIL={{ webmail_type or 'none' }} + +#Antivirus solution +ANTIVIRUS={{ antivirus_enabled or 'none' }} + +#Antispam solution +#ANTISPAM={{ antispam_enabled or 'none'}} + +#Dav server implementation +WEBDAV={{ webdav_enabled or 'none' }} ################################### # Server behavior diff --git a/setup/templates/steps/initial-config.html b/setup/templates/steps/initial-config.html new file mode 100644 index 00000000..d71d2971 --- /dev/null +++ b/setup/templates/steps/initial-config.html @@ -0,0 +1,58 @@ +{% call macros.panel("info", "Step 0 - Initial configuration") %} +

Before starting some variables must be st

+ +
+ + +
+ +
+ + +
+ +
+ + +
+ +
+ +
+ +
+ +
+ + +
+ +
+ +
+ +
+ + +
+ +
+ + +
+ +
+ +
+ +{% endcall %} diff --git a/setup/templates/steps/root.html b/setup/templates/steps/root.html deleted file mode 100644 index f32c2250..00000000 --- a/setup/templates/steps/root.html +++ /dev/null @@ -1,8 +0,0 @@ -{% call macros.panel("info", "Step 0 - Set root path") %} -

Before starting root path must be set

- -
- - -
-{% endcall %} diff --git a/setup/templates/steps/services.html b/setup/templates/steps/services.html index e80b4ff4..e6ee88aa 100644 --- a/setup/templates/steps/services.html +++ b/setup/templates/steps/services.html @@ -9,7 +9,7 @@ manage your email domains, users, etc.

-
+
@@ -21,7 +21,7 @@ accessing messages for beginner users.

-
+

@@ -38,15 +38,22 @@ also disable the antivirus if required (it does use aroung 1GB of ram).

+
+ +
+ {% endcall %} diff --git a/setup/templates/wizard.html b/setup/templates/wizard.html index bbebe569..5a15af6f 100644 --- a/setup/templates/wizard.html +++ b/setup/templates/wizard.html @@ -9,11 +9,11 @@ {% endcall %}
- {% include "steps/root.html" %} + {% include "steps/initial-config.html" %} {% include "steps/flavor.html" %} {% include "steps/expose.html" %} {% include "steps/services.html" %} - {% include "steps/optional.html" %} +