0x01 Kubectl 自动补全
source <(kubectl completion bash) # 针对bash环境
source <(kubectl completion zsh) # 针对zsh环境
0x02 init 时使用本地仓库
kubeadm init --kubernetes-version=v1.11.1 --pod-network-cidr=10.244.0.0/16 --image-repository=harbor.xa-test.com/kube
启动 k8s 集群
0x03 Unable to update cni config: No networks found in /etc/cni/net
错误如下:
Unable to update cni config: No networks found in /etc/cni/net
Container runtime network not ready: NetworkReady=false reason:NetworkPluginNotReady message
解决方法是安装 flannel:
sysctl net.bridge.bridge-nf-call-iptables=1
kubectl apply -f https://raw.githubusercontent.com/coreos/flannel/v0.10.0/Documentation/kube-flannel.yml