Skip to content

Kubeconfig Setup on AKS

Obtaining a Kubernetes Configuration for AKS

Given that you know:

  • the name of the resource group you installed to $rg
  • the name of the Kubernetes cluster you installed $cluster
  • the region you installed to $region

You can use the az command line tool to export a Kubernetes config file:

bash
az aks get-credentials --name $cluster --file ~/.kube/aks/$cluster-$region.config --resource-group $rg --admin

Setup for Azure Console

You may see the following note in your Azure console for the AKS cluster of your Yellowbrick instance.

INFO

The client '{your-account-name}' with object id '{identifier}' does not have authorization to perform action 'Microsoft.Resources/subscriptions/resourceGroups/read' over scope '/subscriptions/{subscription}/resourceGroups/{resourcegroup}' or the scope is invalid. If access was recently granted, please refresh your credentials.

To resolve this, configure your role to add a Role Assignment of Azure Kubernetes Service Cluster Admin Role under Access control (IAM) in the Azure console for the AKS cluster.