Page MenuHomec4science

settings_dev.py
No OneTemporary

File Metadata

Created
Thu, Jun 27, 15:51

settings_dev.py

# settings for dev.py
import environ
# If using in your own project, update the project namespace below
from django_app.settings import *
env = environ.Env(
# set casting, default value
DEBUG=(bool, False)
)
# False if not in os.environ
DEBUG = env('DEBUG')
# Raises django's ImproperlyConfigured exception if SECRET_KEY not in os.environ
SECRET_KEY = env('SECRET_KEY')
# wildcard to change for production
ALLOWED_HOSTS = ['*']
# }
DATABASES = {
# read os.environ['DATABASE_URL'] and raises ImproperlyConfigured exception if not found
'default':
{
'ENGINE': 'django.db.backends.mysql',
'DBNAME': env('DBNAME'),
'DBUSER': env('DBUSER'),
'DBPASSWORD': env('DBPASSWORD'),
'DBHOST': env('DBHOST'),
'PORT': '5432',
}
}
# Env.db_url_config('sqlite:////full/path/to/your/file.sqlite')
# {'ENGINE': 'django.db.backends.sqlite3', 'HOST': '', 'NAME': '/full/path/to/
# ˓→your/file.sqlite', 'PASSWORD': '', 'PORT': '', 'USER': ''}

Event Timeline