Closed lamoni closed 2 years ago
That would definitely be useful! I'll have a think about how to add it, I'm mostly considering whether to add them as overrides to the TOML config (which would also allow configuration to be done without a TOML config file at all), or whether (as you suggested) add them as interpolated values to a config file.
The former would be simpler, though a bit less flexible, and maybe not suitable for complex/nested fields.
The latter would be more flexible, but a bit more work to add (i.e. the template interpolation would have to be done before processing the file, instead of processing the file, then overwriting with any found environment variable values).
Is it possible to add reading from environmental variables for the ocypod config TOML file? This would be particularly useful for the docker container, so one doesn't need to: templatize the TOML file -> "manually" interpolate the password -> save file -> add to docker container/image -> delete TOML file to protect sensitive information (or some other hacky variation of that).
This same concept can be found in Grafana's TOML configuration files using "${ENV_VAR_NAME_HERE}" syntax: https://grafana.com/docs/grafana/latest/auth/ldap/
Thanks!