> For the complete documentation index, see [llms.txt](https://www.devops.buzz/public/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://www.devops.buzz/public/aks/dashboard.md).

# Dashboard

## Access dashboard

Allow full access.

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

{% hint style="info" %}
If you want to allow minimum access, use the following RBAC: <https://raw.githubusercontent.com/kubernetes/kubernetes/master/cluster/addons/dashboard/dashboard-rbac.yaml>
{% endhint %}

Forward port.

```
kubectl port-forward \
  $(kubectl -n kube-system get pods | grep kubernetes-dashboard | awk '{print $1; exit}') \
  9090:9090 -n kube-system
```

Then access: <http://127.0.0.1:9090>

Alternatively you can run:

```bash
az aks browse --resource-group myResourceGroup --name myAKSCluster
```

### References

<https://docs.microsoft.com/pt-br/azure/aks/kubernetes-dashboard>&#x20;

<https://blog.jcorioland.io/archives/2018/08/29/azure-aks-rbac-kubernetes-dashboard.html>&#x20;

<https://pascalnaber.wordpress.com/2018/06/17/access-dashboard-on-aks-with-rbac-enabled/>

## Remove/uninstall dashboard

{% hint style="warning" %}
Required az cli version >=2.0.68&#x20;
{% endhint %}

```
az account set --subscription "YOUR-SUBSCRIPTION"
az aks disable-addons -a kube-dashboard --resource-group YOUR-RG --name YOUR-CLUSTER
```
