Proper configuration initialization even when the app is wrapped by uwsgi

This commit is contained in:
Fabio Manganiello 2022-06-14 10:41:27 +02:00
parent 419220c6c9
commit 9577e02d7f

View file

@ -1,6 +1,11 @@
import os
from .cli import get_args
from .config import init_config
init_config()
opts, _ = get_args()
config_file = os.path.join(opts.dir, 'config.yaml')
init_config(config_file=config_file, content_dir=opts.dir)
from .app import app