I have installed the Google Cloud tools on my Linux box as described here with:
curl https://sdk.cloud.google.com | sudo bash
sudo gcloud init
sudo gcloud components install kubectl beta
So far so good. However when I run kubectl
I get the error
$ kubectl cluster-info
error: failed to negotiate an api version; server supports: map[], client supports: map[batch/v2alpha1:{} policy/v1alpha1:{} rbac.authorization.k8s.io/v1alpha1:{} authentication.k8s.io/v1beta1:{} authorization.k8s.io/v1beta1:{} componentconfig/v1alpha1:{} autoscaling/v1:{} v1:{} apps/v1alpha1:{} batch/v1:{} extensions/v1beta1:{} federation/v1beta1:{}]
Do you have any idea what I'm doing wrong or what I have to configure?
Looks like a version mismatch. What's the
gcloud version
that you have?If you want to install
kubectl
, you should install using these instructions to get the latest version (also, apt and the gcloud component manager don't play nice together).