Search code examples
azure-aksservice-principal

How do I find out which service principal an azure kubernetes cluster uses?


We have created an AKS (Azure Kubernetes) cluster. How can I find out which service principal is assigned to the cluster?

It seems to be not shown anywhere in the GUI.


Solution

  • easiest way is opening up cloud shell and doing this:

    az aks list 
    

    and looking at the result. it would show the id or the service principal

    an alternative would be doing this:

    az aks show -n aks_name -g rg_name --query servicePrincipalProfile