我在耕耘机方面遇到了以下问题:
Type Reason Age From Message
---- ------ ---- ---- -------
Warning FailedCreate 18s (x15 over 1m) replicaset-controller Error creating: pods "tiller-deploy-6f65cf89f-" is forbidden: error looking up service account k8s-tiller/k8s-tiller: serviceaccount "k8s-tiller" not found
但是,k8s-tiller
服务帐户存在(在默认命名空间中)。
我如何进一步调查此事?是否可能在 k8s-tiller
命名空间中查找,如果可以,我可以手动创建服务帐户吗?
最佳答案
我在执行以下操作之前遇到了 helm 问题:
curl https://raw.githubusercontent.com/helm/helm/master/scripts/get | bash
kubectl create serviceaccount --namespace kube-system tiller
kubectl create clusterrolebinding tiller-cluster-rule --clusterrole=cluster-admin --serviceaccount=kube-system:tiller
kubectl patch deploy --namespace kube-system tiller-deploy -p '{"spec":{"template":{"spec":{"serviceAccount":"tiller"}}}}'
helm init --service-account tiller / helm init --service-account tiller --upgrade(in case you have already done heln init)
希望这对您有帮助。
关于Kubernetes RS Controller - 查找服务帐户 k8s-tiller/k8s-tiller : serviceaccount "k8s-tiller" not found 时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53612715/