我在Medium上按照本教程在AWS上部署Kubernetes集群: https://medium.com/containermind/how-to-create-a-kubernetes-cluster-on-aws-in-few-minutes-89dda10354f4
但是,当我启动Kubernetes仪表板时,我发现以下错误:
configmaps is forbidden: User "kube" cannot list configmaps in the namespace "default"
persistentvolumeclaims is forbidden: User "kube" cannot list persistentvolumeclaims in the namespace "default"
secrets is forbidden: User "kube" cannot list secrets in the namespace "default"
services is forbidden: User "kube" cannot list services in the namespace "default"
ingresses.extensions is forbidden: User "kube" cannot list ingresses.extensions in the namespace "default"
为什么会这样?
答案 0 :(得分:6)
问题是本教程的第13步是:
kops获取秘密kube --type secret -oplaintext
应该是:
kops获取秘密admin -oplaintext
答案 1 :(得分:3)
您已登录的User
kube
,无权列出K8跟踪的对象。您可以提升kube
的权限,也可以创建具有正确权限的ServiceAccount
来列出这些对象。