Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

simplify viper flag unmarshaling #868

Closed
mflendrich opened this issue Sep 22, 2020 · 2 comments
Closed

simplify viper flag unmarshaling #868

mflendrich opened this issue Sep 22, 2020 · 2 comments
Labels
area/debt stale Will be closed unless advocated for within 7 days

Comments

@mflendrich
Copy link
Contributor

It is possible to remove one layer of logic (and tests) in flag handling by replacing the config.Xxx = viper.GetXxx("xxx") calls (and the ifology for default values) by the unmarshaler in viper.

Context: https://github.com/Kong/kubernetes-ingress-controller/pull/866/files#r492612779

A possible extension of this task would be using cobra to wrap the flags in the context of a cobra.Command instead of defining them globally in main.

@mflendrich mflendrich changed the title viper/ simplify viper flag unmarshaling Sep 22, 2020
@mflendrich mflendrich removed the trello label Oct 30, 2020
@stale
Copy link

stale bot commented Mar 20, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale Will be closed unless advocated for within 7 days label Mar 20, 2021
@mflendrich
Copy link
Contributor Author

KIC 2.0 will come with flag handling rebuilt from scratch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/debt stale Will be closed unless advocated for within 7 days
Projects
None yet
Development

No branches or pull requests

1 participant