Kubernetes dashboard starting with Forbidden Errors

12/12/2019

How do you apply already create clusterrolebindings to a cluster in Azure Kubernetes?

I have a new cluster and I'm trying to open and view it in the browser, but I am getting forbidden errors.

I tried to run this script, but the terminal says I've already created it. Now I don't know how to apply it to this cluster. Is there a way to do this in the Azure GUI? Any help or suggestions would be great. Thanks!!

az aks get-credentials --resource-group myAKScluster --name myAKScluster --admin

kubectl create clusterrolebinding kubernetes-dashboard --clusterrole=cluster-admin --serviceaccount=kube-system:kubernetes-dashboard

az aks browse --resource-group myAKScluster --name myAKScluster

enter image description here

enter image description here

-- bcook
azure
dashboard
kubernetes
rbac

1 Answer

12/13/2019

It because that you enable the RBAC of your AKS cluster and access to it has been disabled by default. You can follow the troubleshooting described here and the solution here.

-- Charles Xu
Source: StackOverflow