Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Add CLI flag `--config` for configuring the global config location #2555
This PR adds a config flag to configure the location of the global config for the
To achieve its goal, this PR required a substantial refactoring of the global config handling. I hope it got simpler.
nkubala left a comment
this actually looks really good! it's definitely more code than before, but I think in general it's easier to reason about. can you rebase so we can get CI green?
also, is this PR meant to be merged before #2590? i'm a bit confused on the order of them since a lot of the code is the same.
Because the `skaffold config` subcommands are in a separate package, they cannot access this flag, therefore this flag cannot be fully global. Signed-off-by: Cornelius Weig <email@example.com>
This package now uses the config utils from pkg/skaffold/config Signed-off-by: Cornelius Weig <firstname.lastname@example.org>
- when retrieving the config for a given kube-context, merge the result with the global values - cache merged config - simplify logic of GetInsecureRegistries, GetLocalCluster, and GetDefaultRepo - allow to override ReadConfigFile with uncached implementation for tests Signed-off-by: Cornelius Weig <email@example.com>