env variables configuration #55 #89
Merged
rozetko
merged 2 commits from env-variables-configuration-#55
into main
2 years ago
Loading…
Reference in new issue
There is no content yet.
Delete Branch 'env-variables-configuration-#55'
Deleting a branch is permanent. It CANNOT be undone. Continue?
Closes #55
This PR makes it possible to configure
hastic
using environment variablesChanges:
config::Environment::with_prefix("HASTIC")
usage because it doesn't support nested keys, e.g.alerting.type
update_from_env
instead (a function copied from here:f3e5fce6bf/src/config.rs (L132)
), it replaces__
in the variables with.
Configuration example:
TODO: we also need to add configuration docs to the readme, I'll do it in a separate PR
I've added task for the docs https://github.com/hastic/hastic/issues/90
maybe we should put here 4347
Reviewers
052e5a5987
.