报错如下:
The connection to the server localhost:8080 was refused - did you specify the right host or port?
是因为我忘记执行如下代码:
mkdir -p $HOME/.kube
sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
sudo chown $(id -u):$(id -g) $HOME/.kube/config
报错如下:
The connection to the server localhost:8080 was refused - did you specify the right host or port?
是因为我忘记执行如下代码:
mkdir -p $HOME/.kube
sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
sudo chown $(id -u):$(id -g) $HOME/.kube/config