From 8bf71dea474695f87c6c49ffeeffff16383a0803 Mon Sep 17 00:00:00 2001 From: Patrick Jentsch Date: Mon, 2 Dec 2019 14:24:33 +0100 Subject: [PATCH] Fix config file name --- config.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/config.py b/config.py index 296316cf..1918d822 100644 --- a/config.py +++ b/config.py @@ -38,14 +38,14 @@ class DevelopmentConfig(Config): os.environ.get('POSTGRES_PASSWORD'), os.environ.get('POSTGRES_DB_NAME') ) - if not os.path.isfile('logs/opaque_web.log'): - file_path = os.path.join(os.getcwd(), 'logs/opaque_web.log') + if not os.path.isfile('logs/nopaque.log'): + file_path = os.path.join(os.getcwd(), 'logs/nopaque.log') log = open(file_path, 'w+') log.close() if os.environ.get('FLASK_CONFIG') == 'development': log_format = ("%(asctime)s - %(levelname)s - %(name)s - " "%(filename)s - %(lineno)d - %(message)s") - logging.basicConfig(filename='logs/opaque_web.log', level='WARNING', + logging.basicConfig(filename='logs/nopaque.log', level='WARNING', format=log_format, datefmt='%Y-%m-%d %H:%M:%S', filemode='w') logger = logging.getLogger(__name__) @@ -71,14 +71,14 @@ class ProductionConfig(Config): os.environ.get('POSTGRES_PASSWORD'), os.environ.get('POSTGRES_DB_NAME') ) - if not os.path.isfile('logs/opaque_web.log'): - file_path = os.path.join(os.getcwd(), 'logs/opaque_web.log') + if not os.path.isfile('logs/nopaque.log'): + file_path = os.path.join(os.getcwd(), 'logs/nopaque.log') log = open(file_path, 'w+') log.close() if os.environ.get('FLASK_CONFIG') == 'production': log_format = ("%(asctime)s - %(levelname)s - %(name)s - " "%(filename)s - %(lineno)d - %(message)s") - logging.basicConfig(filename='logs/opaque_web.log', level='ERROR', + logging.basicConfig(filename='logs/nopaque.log', level='ERROR', format=log_format, datefmt='%Y-%m-%d %H:%M:%S', filemode='w') logger = logging.getLogger(__name__)