# This file is imported by the Mailman Suite. It is used to override # the default settings from /usr/share/mailman3-web/settings.py. # SECURITY WARNING: keep the secret key used in production secret! #>GNUNUX SECRET_KEY = '{{ general.mailman.postorius_secret_key }}' #GNUNUX #'*' '{{ general.revprox.revprox_client.revprox_client_external_domainnames[0] }}' #GNUNUX # Mailman API credentials #MAILMAN_REST_API_URL = 'http://localhost:8001' #MAILMAN_REST_API_USER = 'restadmin' #MAILMAN_REST_API_PASS = 'T0zVrLFZBJrftkW9Sjs660sEr/P3zehYGYPuo93LSGZT1KHd' #MAILMAN_ARCHIVER_KEY = 'BzzgFI+QbeFOsGFy0Q6wfD5cp9fQvk1o' #MAILMAN_ARCHIVER_FROM = ('127.0.0.1', '::1') #GNUNUX #'ENGINE': 'django.db.backends.sqlite3', #'ENGINE': 'django.db.backends.postgresql_psycopg2', 'ENGINE': 'django.db.backends.postgresql_psycopg2', #GNUNUX #'NAME': '/var/lib/mailman3/web/mailman3web.db', #GNUNUX #'USER': '', #'PASSWORD': '', #GNUNUX #'HOST': '', 'ENGINE': 'django.db.backends.postgresql_psycopg2', #FIXME same database has mailman? 'NAME': '{{ general.postgresql.pg_client_database }}', 'USER': '{{ general.postgresql.pg_client_username }}', # PostgreSQL username 'PASSWORD': '{{ general.postgresql.pg_client_password }}', # PostgreSQL password 'HOST': '{{ general.postgresql.pg_client_server_domainname }}', # Database server # 'CONN_MAX_AGE': 300, #>GNUNUX # PORT: set to empty string for default. 'PORT': '', # OPTIONS: Extra parameters to use when connecting to the database. 'OPTIONS': { # Set sql_mode to 'STRICT_TRANS_TABLES' for MySQL. See # https://docs.djangoproject.com/en/1.11/ref/ # databases/#setting-sql-mode #'init_command': "SET sql_mode='STRICT_TRANS_TABLES'", #>GNUNUX 'sslmode': 'verify-full', 'sslcert': '{{ general.tls_cert_directory }}/postgresql_postorius.crt', 'sslkey': '{{ general.tls_key_directory }}/postgresql_postorius.key', 'sslrootcert': '{{ general.tls_ca_directory }}/PostgreSQL.crt', #GNUNUX LOGGING = { 'version': 1, 'disable_existing_loggers': False, 'formatters': { 'verbose': { 'format': '%(levelname)s - [%(asctime)s] - %(name)s.%(funcName)s:%(lineno)s - %(message)s' } }, 'handlers': { 'apps': { 'level': 'DEBUG', 'class': 'logging.handlers.SysLogHandler', 'formatter': 'verbose', 'facility': 'local7', 'address': '/dev/log', } }, 'loggers': { 'apps': { 'handlers': ['apps'], 'level': 'DEBUG', 'propagate': True, } } } #GNUNUX SECURE_PROXY_SSL_HEADER = ('HTTP_X_FORWARDED_PROTO', 'https') #GNUNUX CSRF_TRUSTED_ORIGINS = ['{{ general.revprox.revprox_client.revprox_client_external_domainnames[0] }}'] #GNUNUX #LANGUAGE_CODE = 'en-us' LANGUAGE_CODE = 'fr' #GNUNUX #DEFAULT_FROM_EMAIL = 'postorius@{}'.format(EMAILNAME) DEFAULT_FROM_EMAIL = '{{ general.mailman.mailman_mail_owner }}' #GNUNUX #SERVER_EMAIL = 'root@{}'.format(EMAILNAME) SERVER_EMAIL = '{{ general.mailman.mailman_mail_owner }}' EMAIL_HOST = "{{ general.smtp.smtp_relay_address }}" EMAIL_PORT = 25 EMAIL_HOST_USER = "{{ general.smtp.smtp_relay_user }}@{{ general.smtp.smtp_client_ip }}" EMAIL_HOST_PASSWORD = "{{ general.smtp.smtp_relay_password }}" EMAIL_USE_TLS = True #FIXME EMAIL_SUBJECT_PREFIX = '[Django] ' #STATIC_URL = '/mailman/postorius_static/' #FORCE_SCRIPT_NAME = '/mailman' #GNUNUX SOCIALACCOUNT_EMAIL_VERIFICATION = 'none' #GNUNUX #POSTORIUS_TEMPLATE_BASE_URL = 'http://localhost/mailman3/' {% set location = general.revprox.revprox_client.revprox_client_external_domainnames[0].revprox_client_location %} POSTORIUS_TEMPLATE_BASE_URL = 'https://{{ general.revprox.revprox_client.revprox_client_external_domainnames[0] }}/{{ location }}' #