2018-09-08 03:43:52 -07:00
|
|
|
import logging
|
|
|
|
|
|
2018-02-08 23:07:19 -05:00
|
|
|
from .base import *
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# SECURITY WARNING: keep the secret key used in production secret!
|
2018-09-08 03:43:52 -07:00
|
|
|
if 'SECRET_KEY' not in os.environ:
|
|
|
|
|
logging.warning(
|
|
|
|
|
"No SECRET_KEY given in environ, please have a check"
|
|
|
|
|
)
|
2019-12-08 17:00:37 +08:00
|
|
|
SECRET_KEY = os.environ.get('SECRET_KEY', "PLEASE_REPLACE_ME")
|
2018-02-08 23:07:19 -05:00
|
|
|
|
|
|
|
|
# SECURITY WARNING: don't run with debug turned on in production!
|
|
|
|
|
DEBUG = False
|
|
|
|
|
|
|
|
|
|
# SECURITY WARNING: use your actual domain name in production!
|
|
|
|
|
ALLOWED_HOSTS = ['*']
|
|
|
|
|
|
|
|
|
|
# Database
|
|
|
|
|
# https://docs.djangoproject.com/en/1.10/ref/settings/#databases
|
|
|
|
|
|
|
|
|
|
DATABASES = {
|
|
|
|
|
'default': {
|
|
|
|
|
'ENGINE': 'django.db.backends.postgresql_psycopg2',
|
|
|
|
|
'NAME': 'postgres',
|
|
|
|
|
'USER': 'postgres',
|
|
|
|
|
'HOST': 'db',
|
|
|
|
|
'PORT': 5432,
|
|
|
|
|
}
|
|
|
|
|
}
|
2018-08-19 04:33:14 -07:00
|
|
|
|
2018-12-29 15:58:21 +08:00
|
|
|
USE_X_FORWARDED_HOST = True
|
|
|
|
|
|
2019-12-08 23:46:46 +08:00
|
|
|
REST_FRAMEWORK['DEFAULT_RENDERER_CLASSES'] = [
|
|
|
|
|
'rest_framework.renderers.JSONRenderer',
|
|
|
|
|
]
|
|
|
|
|
|
2018-08-19 04:33:14 -07:00
|
|
|
try:
|
|
|
|
|
from .local_settings import *
|
|
|
|
|
except ImportError:
|
|
|
|
|
pass
|