userver-framework / userver

Production-ready C++ Asynchronous Framework with rich functionality
https://userver.tech
Apache License 2.0
2.37k stars 275 forks source link

Support `#file` in YamlConfig to read values from file #548

Closed apolukhin closed 3 months ago

apolukhin commented 4 months ago

Could be useful for example for dynamic-config.defaults#file: /etc/userver/dyn-configs-defaults.yaml, secdist or components with big configs

See the #env code for inspiration https://github.com/userver-framework/userver/commit/6b2b8b36ae903abaf674815eb407aae11af87d8d and do not forget to add docs and tests.

Internal ticket: 7731