#flannel启动报错

unable to recognize "kube-flannel.yml": no matches for kind "ClusterRole" in version "rbac.authorization.k8s.io/v1beta1"
unable to recognize "kube-flannel.yml": no matches for kind "ClusterRoleBinding" in version "rbac.authorization.k8s.io/v1beta1"

#将kube-flannel.yml文件下面两行修改后重启服务

#kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1beta1   改成-->  apiVersion: rbac.authorization.k8s.io/v1

#kind: ClusterRoleBinding
apiVersion: rbac.authorization.k8s.io/v1beta1   改成-->   apiVersion: rbac.authorization.k8s.io/v1

#重启服务

]# kubectl delete -f kube-flannel.yml  
]# kubectl create -f kube-flannel.yml

Logo

K8S/Kubernetes社区为您提供最前沿的新闻资讯和知识内容

更多推荐