"""Application's configuration file""" from pathlib import Path # path configuration # let's guess that :file:`config.py` is located here : :file:`{rootpath}/webapp/` _here = Path(__file__).resolve().parent rootpath = _here.parent "root project directory" from yaml import safe_load # loads database credentials local_params_file = rootpath / "params.yaml" with open(local_params_file, 'r') as file_handle: params_content = safe_load(file_handle) dbadmin = params_content['dbadmin'] dbpassword = params_content['dbpassword'] server_ip = params_content['server_ip']