doitaway Sorry for late answer... from my notes taken at that time:
- Create your service principal
- Export environment variables AAD_SERVICE_PRINCIPAL_CLIENT_ID and AAD_SERVICE_PRINCIPAL_CLIENT_SECRET with service principal ID and password to myagent/.env
- Add your service principal as contributor to the resource group of AKS
- Add the service principal to the AKS IAM group Azure Kubernetes Service RBAC Cluster Admin Role
- login to azure as service principal: az login --service-principal -u your_service_principal_id -p your_service_principal_pwd -t your_tenant_id
- retreive credentials: az aks get-credentials --resource-group your_aks_rg --name your_aks_cluster
- convert them to kubelogin format: kubelogin convert-kubeconfig -l spn
Hope this helps