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

kubestr breaks when KUBECONFIG points at multiple config files #146

Open
larsks opened this issue Dec 17, 2022 · 0 comments
Open

kubestr breaks when KUBECONFIG points at multiple config files #146

larsks opened this issue Dec 17, 2022 · 0 comments

Comments

@larsks
Copy link

larsks commented Dec 17, 2022

kubectl supports setting KUBECONFIG to a colon-delimited list of configuration files (KUBECONFIG=/path/to/config1:/some/other/config:$HOME/.kube/config). This is also supported by the underlying client-go package.

kubestr falls over when KUBECONFIG is configured with mulitple config files:

$ kubestr
stat /home/lars/.kube/configs/default:/home/lars/.kube/configs/cluster1:/home/lars/.kube/configs/cluster2
Error: ...:: no such file or directory

It's possible to work around that by giving kubestr a KUBECONFIG of it's very own:

kubectl config view --flatten --minify > kubeconfig
KUBECONFIG=$PWD/kubeconfig kubestr

But it would be nice if kubestr would support the same semantics as kubectl.

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

No branches or pull requests

1 participant