settings: load local_settings.py from environment

This commit is contained in:
Frédéric Péters 2015-07-02 10:55:15 +02:00
parent d0b917c730
commit f9d9a6e54f
1 changed files with 5 additions and 0 deletions

View File

@ -81,3 +81,8 @@ USE_TZ = True
# https://docs.djangoproject.com/en/1.7/howto/static-files/
STATIC_URL = '/static/'
local_settings_file = os.environ.get('WELCO_SETTINGS_FILE',
os.path.join(os.path.dirname(__file__), 'local_settings.py'))
if os.path.exists(local_settings_file):
execfile(local_settings_file)