Expose more email settings

This commit is contained in:
Finn Stutzenstein 2020-10-28 08:34:43 +01:00
parent 266f9b73e9
commit 6943c3d18f
No known key found for this signature in database
GPG Key ID: 9042F605C6324654
6 changed files with 28 additions and 2 deletions

View File

@ -55,6 +55,17 @@ Finally, you can start the instance using ``docker-compose``::
$ # ...
$ docker-compose down
More settings
-------------
When generating the ``docker-compose.yml``, more settings can be adjusted in the
``docker/.env`` file. All changes for the backend are passed into djangos ``settings.py``.
You can find more information about most settings `here
<https://github.com/OpenSlides/OpenSlides/blob/master/server/SETTINGS.rst>`_. To generate
the ``docker-compose.yml`` use this command::
$ ( set -a; source .env; m4 docker-stack.yml.m4 ) > docker-stack.yml
Docker Swarm Mode
-----------------

View File

@ -63,6 +63,9 @@ EMAIL_HOST=
EMAIL_HOST_PASSWORD=
EMAIL_HOST_USER=
EMAIL_PORT=
EMAIL_USE_SSL=
EMAIL_USE_TLS=
EMAIL_TIMEOUT=
JITSI_DOMAIN=
JITSI_ROOM_PASSWORD=
JITSI_ROOM_NAME=

View File

@ -59,6 +59,9 @@ x-osserver-env: &default-osserver-env
EMAIL_HOST_PASSWORD: "ifenvelse(`EMAIL_HOST_PASSWORD',)"
EMAIL_HOST_USER: "ifenvelse(`EMAIL_HOST_USER',)"
EMAIL_PORT: ifenvelse(`EMAIL_PORT', 25)
EMAIL_USE_SSL: "ifenvelse(`EMAIL_USE_SSL',)"
EMAIL_USE_TLS: "ifenvelse(`EMAIL_USE_TLS',)"
EMAIL_TIMEOUT: "ifenvelse(`EMAIL_TIMEOUT',)"
ENABLE_ELECTRONIC_VOTING: "ifenvelse(`ENABLE_ELECTRONIC_VOTING', False)"
ENABLE_SAML: "ifenvelse(`ENABLE_SAML', False)"
INSTANCE_DOMAIN: "ifenvelse(`INSTANCE_DOMAIN', http://example.com:8000)"

View File

@ -58,6 +58,9 @@ x-osserver-env: &default-osserver-env
EMAIL_HOST_PASSWORD: "ifenvelse(`EMAIL_HOST_PASSWORD',)"
EMAIL_HOST_USER: "ifenvelse(`EMAIL_HOST_USER',)"
EMAIL_PORT: ifenvelse(`EMAIL_PORT', 25)
EMAIL_USE_SSL: "ifenvelse(`EMAIL_USE_SSL',)"
EMAIL_USE_TLS: "ifenvelse(`EMAIL_USE_TLS',)"
EMAIL_TIMEOUT: "ifenvelse(`EMAIL_TIMEOUT',)"
ENABLE_ELECTRONIC_VOTING: "ifenvelse(`ENABLE_ELECTRONIC_VOTING', False)"
ENABLE_SAML: "ifenvelse(`ENABLE_SAML', False)"
INSTANCE_DOMAIN: "ifenvelse(`INSTANCE_DOMAIN', http://example.com:8000)"

View File

@ -59,11 +59,14 @@ DEMO_USERS = get_env("DEMO_USERS", default=None)
DEMO_USERS = json.loads(DEMO_USERS) if DEMO_USERS else None
# Email settings
# For SSL/TLS specific settings see https://docs.djangoproject.com/en/1.11/topics/email/#smtp-backend
# For an explaination and more settings values see https://docs.djangoproject.com/en/2.2/topics/email/#smtp-backend
EMAIL_HOST = get_env("EMAIL_HOST", "postfix")
EMAIL_PORT = get_env("EMAIL_PORT", 25, int)
EMAIL_HOST_USER = get_env("EMAIL_HOST_USER", "")
EMAIL_HOST_PASSWORD = get_env("EMAIL_HOST_PASSWORD", "")
EMAIL_USE_SSL = get_env("EMAIL_USE_SSL", False, bool)
EMAIL_USE_TLS = get_env("EMAIL_USE_TLS", False, bool)
EMAIL_TIMEOUT = get_env("EMAIL_TIMEOUT", None, int)
DEFAULT_FROM_EMAIL = get_env("DEFAULT_FROM_EMAIL", "noreply@example.com")
# Increasing Upload size to 100mb (default is 2.5mb)

View File

@ -45,12 +45,15 @@ DEBUG = %(debug)s
RESET_PASSWORD_VERBOSE_ERRORS = True
# Email settings
# For SSL/TLS specific settings see https://docs.djangoproject.com/en/1.11/topics/email/#smtp-backend
# For an explaination and more settings values see https://docs.djangoproject.com/en/2.2/topics/email/#smtp-backend
EMAIL_HOST = 'localhost'
EMAIL_PORT = 587
EMAIL_HOST_USER = ''
EMAIL_HOST_PASSWORD = ''
EMAIL_USE_SSL = False
EMAIL_USE_TLS = False
EMAIL_TIMEOUT = None
DEFAULT_FROM_EMAIL = 'noreply@example.com'
# Increasing Upload size to 100mb (default is 2.5mb)