juxt / aero

A small library for explicit, intentful configuration.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Provide support / API for loading a configuration directory - a la linux config.d ?

ieugen opened this issue · comments

Hi,

Context: I am looking at aero for configuration loading but we have a use case that might not fit ?!

I know there is a reason why aero suggests using a single file but there are valid reasons for having configurations in a directory or loaded from multiple places.

A good write up is here, but I'm sure there are more: https://www.redhat.com/sysadmin/etc-configuration-directories

For example, in linux, files are loaded from a config.d/ directory in sorted order, because it allows users to ADD configs that will not be overwritten on app upgrade for example.

Another personal example: in one app I load configs from a directory because we keep secrets in HashiCorp Vault and we save those as a file, alongside the public config which we store in git.
Plus we generate some other data during container image build as config file.

For us, it made sense to load configuration from a conf.d/ directory.