X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/b9055c7fc8caed025fd28c12532bd462edb8c78d..f1e6f920e97685377e877e93c76e2f2c2fd83b26:/redakcja/settings/common.py?ds=sidebyside diff --git a/redakcja/settings/common.py b/redakcja/settings/common.py index 24a4258c..377a4d50 100644 --- a/redakcja/settings/common.py +++ b/redakcja/settings/common.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- import os.path -PROJECT_ROOT = os.path.realpath(os.path.dirname(__file__)) +PROJECT_ROOT = os.path.realpath(os.path.dirname(os.path.dirname(__file__))) DEBUG = False TEMPLATE_DEBUG = DEBUG @@ -140,3 +140,16 @@ WL_API_CONFIG = { } # Import localsettings file, which may override settings defined here + +from localsettings import * + +try: + import logging + if os.path.isfile(LOGGING_CONFIG_FILE): + import logging.config + logging.config.fileConfig(LOGGING_CONFIG_FILE) + else: + import sys + logging.basicConfig(stream=sys.stderr) +except ImportError as exc: + raise