From 04c50ec31411339052d238571e08691f91264f86 Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Thu, 14 May 2015 01:19:55 +0200 Subject: [PATCH] support local settings Signed-off-by: Nico Schottelius --- dynamicweb/.gitignore | 1 + dynamicweb/settings.py | 11 +++++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) create mode 100644 dynamicweb/.gitignore diff --git a/dynamicweb/.gitignore b/dynamicweb/.gitignore new file mode 100644 index 00000000..fd2351ef --- /dev/null +++ b/dynamicweb/.gitignore @@ -0,0 +1 @@ +settings_local.py diff --git a/dynamicweb/settings.py b/dynamicweb/settings.py index 9602ee37..902dbd0b 100644 --- a/dynamicweb/settings.py +++ b/dynamicweb/settings.py @@ -23,9 +23,11 @@ BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) SECRET_KEY = 'xlhyv_l5-z6e8_@q6)n0up1a0$5-aad7d)om2t8g$bi6*@q44i' # SECURITY WARNING: don't run with debug turned on in production! -DEBUG = True +DEBUG = False -ALLOWED_HOSTS = [] +ALLOWED_HOSTS = [ + ".ungleich.ch", + "digital.glarus.ungleich.ch" ] # Application definition @@ -103,3 +105,8 @@ USE_TZ = True STATIC_URL = '/static/' STATIC_ROOT = os.path.join(BASE_DIR, 'static') + +try: + from .settings_local import * +except ImportError as e: + print(e)