You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Set prefix in /etc/confd/conf.d/myapp.toml to myapp
Set prefix in /etc/confd/conf.d/yourapp.toml to yourapp
Current behaviour:
Debug logs:
DEBUG Loading template resource from /etc/confd/conf.d/myapp.toml
DEBUG Retrieving keys from store
DEBUG Key prefix set to /production
DEBUG Processing key=/production/foo
DEBUG Loading template resource from /etc/confd/conf.d/yourapp.toml
DEBUG Retrieving keys from store
DEBUG Key prefix set to /production
DEBUG Processing key=/production/foo
Expected behaviour:
Debug logs:
DEBUG Loading template resource from /etc/confd/conf.d/myapp.toml
DEBUG Retrieving keys from store
DEBUG Key prefix set to /production/myapp
DEBUG Processing key=/production/myapp/foo
DEBUG Loading template resource from /etc/confd/conf.d/yourapp.toml
DEBUG Retrieving keys from store
DEBUG Key prefix set to /production/yourapp
DEBUG Processing key=/production/yourapp/foo
Does this make sense? is there a reason/use-case I'm missing?
I realize changing this would be a breaking change, so I'm not sure if you would consider this?
Suggestion
if tr.Prefix is set, concat with config.Prefix
The text was updated successfully, but these errors were encountered:
It appears the behavior was modified in this PR. I think this is the appropriate behavior for the CLI, but I'm not sure there is a reason why "nested" prefixes of the .toml configs couldn't be concatenated.
Thank you so much for maintaining this fork!
Currently confd config prefix overrides the template resource prefix, which seems counter-intuitive:
confd/pkg/template/resource.go
Line 93 in 8a76b9a
Scenario:
prefix
in/etc/confd/confd.toml
toproduction
prefix
in/etc/confd/conf.d/myapp.toml
tomyapp
prefix
in/etc/confd/conf.d/yourapp.toml
toyourapp
Current behaviour:
Debug logs:
Expected behaviour:
Debug logs:
Does this make sense? is there a reason/use-case I'm missing?
I realize changing this would be a breaking change, so I'm not sure if you would consider this?
Suggestion
if
tr.Prefix
is set, concat withconfig.Prefix
The text was updated successfully, but these errors were encountered: