controller.settings.prod_TEMPLATE#
Template for settings used in a production environment.
Create a copy of this file and name it “prod.py”.
Fill in the missing values. A short description is given below each field.
Documentation: https://docs.djangoproject.com/en/3.2/ref/settings/
Module Contents#
- CHAT_INSTALLED_BOTS#
Installed bots.
Each key is the bot name, and the value is a 4-tuple (module, class, positional arguments, keyword arguments).
- MEDIA_ROOT#
Path where files uploaded by users will be saved.
- ALLOWED_HOSTS = ['localhost', '127.0.0.1']#
A list of strings representing the host/domain names that this Django site can serve.
- _db_engine = ''#
Database engine.
- Should be one of:
MySQL
Oracle
PostgreSQL
SQLite3
- DATABASES#
Database settings.
Documentation: https://docs.djangoproject.com/en/4.0/ref/databases/
- CORS_ALLOWED_ORIGINS: list[str] = []#
A list of origins that are authorized to make cross-site HTTP requests.
To use regular expressions, replace it with CORS_ALLOWED_ORIGIN_REGEXES.
Documentation: https://github.com/adamchainz/django-cors-headers
- CSRF_TRUSTED_ORIGINS: list[str] = []#
A list of trusted origins for unsafe requests (e.g. POST).
- CHANNEL_LAYERS#
Settings for Django Channels.
Documentation: https://github.com/django/channels_redis
- _ssl = True#
Whether SSL should be required.
It should be set to False in temporary servers that cannot be accessed via HTTPS.
- SECURE_HSTS_SECONDS = 3600#
Number of seconds after which the browser should only use HTTPS.
For example: if set to 604800, then any browser that visits the page over HTTPS will refuse to connect to the website via HTTP, which makes the website unavailable for previous users if an HTTPS connection is no longer possible (e.g. expired SSL certificate).
Documentation: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security
- CHAT_ENABLE_ROOMS = False#
- DEBUG = False#
- CORS_ALLOW_CREDENTIALS = True#
- SECURE_SSL_REDIRECT = True#
- error = 'Environment variable SECRET_KEY not set or empty'#