Signed-off-by: Jeroen Oudshoorn <oudshoorn.jeroen@gmail.com>
This commit is contained in:
Jeroen Oudshoorn
2023-10-17 21:52:34 +02:00
parent 450b73c144
commit 8578fcbe45
26 changed files with 105 additions and 87 deletions

View File

@ -223,13 +223,13 @@ def load_config(args):
if user_config:
config = merge_config(user_config, config)
except Exception as ex:
logging.error("There was an error processing the configuration file:\n%s ",ex)
logging.error("There was an error processing the configuration file:\n%s ", ex)
sys.exit(1)
# dropins
dropin = config['main']['confd']
if dropin and os.path.isdir(dropin):
dropin += '*.toml' if dropin.endswith('/') else '/*.toml' # only toml here; yaml is no more
dropin += '*.toml' if dropin.endswith('/') else '/*.toml' # only toml here; yaml is no more
for conf in glob.glob(dropin):
with open(conf) as toml_file:
additional_config = toml.load(toml_file)