From f8e546007c87fcedb15685d21e8b666be0515532 Mon Sep 17 00:00:00 2001 From: "Maxime Alves LIRMM@home" Date: Fri, 4 Dec 2020 18:12:42 +0100 Subject: [PATCH] [conf] lower loglevel string --- halfapi/conf.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/halfapi/conf.py b/halfapi/conf.py index 5f7b16d..6d0d751 100644 --- a/halfapi/conf.py +++ b/halfapi/conf.py @@ -12,6 +12,7 @@ It defines the following globals : - PROJECT_NAME (str) - DOMAINSDICT ({domain_name: domain_module}) - PRODUCTION (bool) + - LOGLEVEL (string) - BASE_DIR (str) - HOST (str) - PORT (int) @@ -47,6 +48,7 @@ logger = logging.getLogger('halfapi') PROJECT_NAME = os.path.basename(os.getcwd()) DOMAINSDICT = lambda: {} PRODUCTION = False +LOGLEVEL = 'info' HOST = '127.0.0.1' PORT = '3000' SECRET = '' @@ -136,4 +138,6 @@ if IS_PROJECT: PRODUCTION = config.getboolean('project', 'production') or False os.environ['HALFAPI_PROD'] = str(PRODUCTION) + LOGLEVEL = config.get('project', 'loglevel').lower() or 'info' + BASE_DIR = config.get('project', 'base_dir', fallback='.') #os.getcwd())