origin: confusing error message for broken kubeconfig
$ _output/local/go/bin/osc get nodes --config=/tmp/.kubeconfig
F0408 12:36:14.378556 4902 get.go:70] Error: no server found for
I ran into this by accident with a “broken” .kubeconfig. Unfortunately I blew it away so I’m not sure the exact scenario, but I could reproduce it using the generated admin .kubeconfig and simply editing the file to set current-context: none. I would surmise there are likely other ways to break it.
The error message is… inscrutable. If what you’re trying to say is that there’s no such context, or you automatically created a context but it has no server … then some message to that effect would be helpful.
About this issue
- Original URL
- State: closed
- Created 9 years ago
- Comments: 26 (17 by maintainers)
Alright. I ran ./oc config use-context default/172-19-17-143:8443/system:admin
then ./oc whoami
then ./oc get nodes again and now it works. Thanks for your help guys.