try to fix container error

This commit is contained in:
zenix 2017-04-13 16:49:36 +09:00
parent 73da11b04c
commit 02d1900e2f

View File

@ -107,6 +107,13 @@ LOGGING = {
} }
} }
# this happens when using container or systems without syslog
# keep things in config would cause file not exists error
_addr = LOGGING['handlers']['accessSysLog']['address']
if type(_add) is str and not os.path.exists(_addr):
LOGGING['handlers'].pop('accessSysLog')
LOGGING['handlers'].pop('errorSysLog')
class Config(dict): class Config(dict):
def __init__(self, defaults=None, load_env=True): def __init__(self, defaults=None, load_env=True):