cookeem / kubeadm-ha

通过kubeadm安装kubernetes高可用集群,使用docker/containerd容器运行时,适用v1.24.x以上版本
MIT License
679 stars 275 forks source link

KUBECONFIG settings cannot be used in general user account #22

Closed iamaugustin closed 6 years ago

iamaugustin commented 6 years ago

If user runs in the general account, I suggest run the following instruction instead of "export KUBECONFIG=/etc/kubernetes/admin.conf".

sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config sudo chown $(id -u):$(id -g) $HOME/.kube/config export KUBECONFIG=$HOME/.kube/config

cookeem commented 6 years ago

Because this guide is run as root, just for my convenience. The method you show is recommended by official.