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

Consider support multiple kubeconfigs #7

Open
Dentrax opened this issue Jan 15, 2021 · 2 comments
Open

Consider support multiple kubeconfigs #7

Dentrax opened this issue Jan 15, 2021 · 2 comments

Comments

@Dentrax
Copy link

Dentrax commented Jan 15, 2021

If we set multiple KUBECONFIG in our $KUBECONFIG env flag, suspicious-pods could not understand and throws an exception:

$ export KUBECONFIG=$KUBECONFIG:$HOME/.kube/config:$HOME/.kube/config-foo:$HOME/.kube/config-bar
$ suspicious-pods

Error: Kubeconfig(ConfigInferenceExhausted { cluster_env: Kubeconfig(MissingInClusterVariables { hostenv: "KUBERNETES_SERVICE_HOST", portenv: "KUBERNETES_SERVICE_PORT" }), kubeconfig: Kubeconfig(ReadFile { path: ":/Users/furkan/.kube/config:/Users/furkan/.kube/config-foo:/Users/furkan/.kube/config-bar", source: Os { code: 2, kind: NotFound, message: "No such file or directory" } }) })

I think it should recognize that if given input is multiple files.

@JTarasovic
Copy link

Looks like the underlying library doesn't really support it. Although they have a workaround listed using kubectl to flatten the configs into a tmp config....

kube-rs/kube#132

@kazk
Copy link

kazk commented Feb 10, 2021

We should have it supported in the next release. kube-rs/kube#411

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants