Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow custom config dirs that extend the default ones. #724

Merged
merged 2 commits into from
Jan 25, 2022

Conversation

tbeadle
Copy link
Contributor

@tbeadle tbeadle commented Jan 24, 2022

A new custom/conf/ directory can be used to hold additional
configuration files that extend the ones in the top-level conf
directory. See the custom/README.md for more information.

.conf.d (e.g. custom/conf/reporting.conf.d/) directories may also
be used to store additional configuration.

In addition, for Config() objects, only read the files once, so that if,
say, Config("processing") is created in multiple places, they'll both
refer to the same object and the conf files would only be read once.

A new AnalysisConfig() class was created to separate the distinction
between these types of "singleton" Config objects that can read from
multiple directories versus ones that just read from an analysis.conf
(or some other single file).

Allow environment variables to be referenced in config files.
Allow config files to use values that are formatted like
%(ENV:SOME_ENVIRONMENT_VARIABLE)s. In certain deployment strategies,
this makes it easier to deal with secrets since they don't need to be
stored on disk anywhere.

Tommy Beadle added 2 commits January 24, 2022 17:42
A new custom/conf/ directory can be used to hold additional
configuration files that extend the ones in the top-level conf
directory. See the custom/README.md for more information.

`.conf.d` (e.g. `custom/conf/reporting.conf.d/`) directories may also
be used to store additional configuration.

In addition, for Config() objects, only read the files once, so that if,
say, Config("processing") is created in multiple places, they'll both
refer to the same object and the conf files would only be read once.

A new AnalysisConfig() class was created to separate the distinction
between these types of "singleton" Config objects that can read from
multiple directories versus ones that just read from an analysis.conf
(or some other single file).

Allow environment variables to be referenced in config files.
Allow config files to use values that are formatted like
%(ENV:SOME_ENVIRONMENT_VARIABLE)s. In certain deployment strategies,
this makes it easier to deal with secrets since they don't need to be
stored on disk anywhere.
Config.get() should only return the items that were actually in the
config file.
@doomedraven
Copy link
Collaborator

as far as i understand this commit overwrites this one no? #711

@tbeadle
Copy link
Contributor Author

tbeadle commented Jan 25, 2022

yes. I'll close that one.

@tbeadle
Copy link
Contributor Author

tbeadle commented Jan 25, 2022

oops. I can't, because you created it. :-)

@doomedraven
Copy link
Collaborator

ok closing that one

@doomedraven doomedraven merged commit e217139 into kevoreilly:master Jan 25, 2022
@doomedraven
Copy link
Collaborator

tested, works fine, thanks

@tbeadle tbeadle deleted the extensible-config branch November 7, 2023 21:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants