1. kubectl run 起来的pod 用 kubectl delete po删不掉

kubectl delete deployment my-nginx

 

kubelet
# 看到最后一行:error: failed to run Kubelet: failed to create kubelet: misconfiguration: kubelet cgroup driver: "cgroupfs" is different from docker cgroup driver: "systemd"


# vim /lib/systemd/system/docker.service
# 将 --exec-opt native.cgroupdriver=systemd  修改为:
#  --exec-opt native.cgroupdriver=cgroupfs
# systemctl daemon-reload 
# systemctl restart docker.service
# kubelet显示正常

 

 

设置API server接收所有主机的请求:

 

MacBook-Mini:~ test$ kubectl proxy --address='0.0.0.0'  --accept-hosts='^*$'
Starting to serve on [::]:8001