Prepare Django for Deployment
- Store application dependencies in a
requirements.txt
file. This file should be located in the root of the Django project next tomanage.py
. - Configure the Django application to use environment variables. The following variables are auto-generated when a Django application or environment is initially created:
SECRET_KEY=
MEDIA_URL=
MEDIA_ROOT=
SQL_ENGINE=
STATIC_URL=
STATIC_ROOT=
DOMAIN_NAME=
ALLOWED_HOSTS=
AWS_S3_REGION_NAME=
AWS_S3_MEDIA_LOCATION=
AWS_S3_STATIC_LOCATION=
AWS_S3_CUSTOM_DOMAIN=
DJANGO_PROJECT_NAME=
- Database environment variables will be generated by AWS RDS when a database is created. Zonké makes these variables available to the application:
SQL_ENGINE=
DATABASE_NAME=
DATABASE_USER=
DATABASE_HOST=
DATABASE_PORT=
DATABASE_PASSWORD=
Additional environment variables can be added on the Zonké dashboard.