settings: add support for local settings

This commit is contained in:
Frédéric Péters 2021-05-31 10:23:45 +02:00
parent 59e1ca3b0b
commit ac1092489d
1 changed files with 7 additions and 0 deletions

View File

@ -117,3 +117,10 @@ USE_TZ = True
# https://docs.djangoproject.com/en/2.2/howto/static-files/
STATIC_URL = '/static/'
local_settings_file = os.environ.get(
'PFWB_ARCHIVES_PROXY_SETTINGS_FILE', os.path.join(os.path.dirname(__file__), 'local_settings.py')
)
if os.path.exists(local_settings_file):
exec(open(local_settings_file).read())