production.py

Disable debug mode

DEBUG = False - In production, this should always be False

Configuration from environment variables

env = os.environ.copy() This line copies any configuration from environment variables
Alternatively, you can set these in a local.py file on the server with:
1
try:
2
from .local import * # noqa
3
except ImportError:
4
pass
Copied!

Mailgun configuration.

Configuration for Mailgun. Mailgun API reference is here

Sentry configuration.

If you are using Sentry. Details on Sentry DSN here

Heroku configuration.

Set ON_HEROKU to true in Config Vars or via Heroku cli'heroku config:set ON_HEROKU=true.
Last modified 26d ago