Replies: 2 comments
-
So I came up with:
By setting |
Beta Was this translation helpful? Give feedback.
-
In my case I can pass flags and have a part of the config loaded via YAML file. let's say an hybrid combination which is what you are looking for to achieve but in order to do so you need to implement a custom mapper. |
Beta Was this translation helpful? Give feedback.
-
So I have some configuration which I think it is too tricky to expose through CLI easily, e.g.:
So I am thinking that it would be cool if I could load config first to set values in this struct, and then use CLI to add set CLI values. So I was thinking of having my own ConfigFlag which would use
BeforeReset
orBeforeResolve
to load data from YAML file into config, with regular YAML loader, and then the rest is handled by kong. Does this sound reasonable and is there something already existing doing this I am missing? From what I was looking into config examples it looks like config files just set defaults for kong fields, but ignores other fields there might be in the struct/file?Beta Was this translation helpful? Give feedback.
All reactions