Skip to content
Samanta Mika edited this page May 3, 2019 · 6 revisions

Prerequisites

Install Azure CLI:

https://docs.microsoft.com/en-us/cli/azure/install-azure-cli?view=azure-cli-latest

Useful commands:

Get AKS credentials for kubectl:

az aks get-credentials --resource-group AksDemo --name AksDemoCluster

Open Kubernetes Dashboard:

az aks browse --resource-group AksDemo --name AksDemoCluster

Useful Links:

How to create Kubernetes Clusters for Azure Dev Spaces

https://docs.microsoft.com/en-us/azure/dev-spaces/get-started-netcore-visualstudio

Troubleshooting

Multiple Azure subscriptions available

When command the following command

az aks get-credentials --resource-group AksDemo --name AksDemoCluster

shows "The operation is not permitted for namespace 'Microsoft.ContainerService'...." message then list all available Azure subscriptions with following command:

az account list

Copy the id of the subscription you want to use with:

az account set --subscription "id"

Access dashboard on AKS with RBAC enabled

When the Kubernetes Dashboard shows errors related to insufficient access rights, create a ClusterRoleBinding which gives the role dashboard-admin to the ServiceAccount:

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

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

Clone this wiki locally