Azure CLI
Microsoft Azure command-line client (az ...) — login, subscriptions, AKS basics.
Official docsLogin & subscriptions
az loginBrowser-based interactive login.
az login --tenant <tenant-id>Pin the login to a specific tenant (multi-tenant accounts).
az login --service-principal -u <appId> -p <secret> --tenant <tenant>Non-interactive SP login. Used in CI.
az account list -o tableAll subscriptions you can see + which is default.
az account set --subscription <id-or-name>Switch the active subscription.
az account showCurrently active subscription + tenant.
Resource groups & generic queries
az group list -o tableAll resource groups in the active subscription.
az group create -n my-rg -l westeuropeCreate a resource group in a region.
az group delete -n my-rg --yes --no-waitTear down a resource group asynchronously. Drops everything inside.
az resource list -g my-rg -o tableEvery resource inside a group.
az resource list --query "[?type=='Microsoft.Storage/storageAccounts'].name"JMESPath query — filter resources to just the names of storage accounts.
AKS
az aks list -o tableAll AKS clusters in the active subscription.
az aks get-credentials -g my-rg -n my-clusterMerge the cluster's kubeconfig into ~/.kube/config.
az aks get-credentials -g my-rg -n my-cluster --adminGet the cluster-admin context (bypasses Azure AD).
az aks browse -g my-rg -n my-clusterOpen the k8s dashboard via a local proxy.
az aks upgrade -g my-rg -n my-cluster --kubernetes-version 1.30.0Upgrade the control plane + node pools.
Storage & container registry
az storage account list -o tableStorage accounts in the active subscription.
az storage blob list --account-name <acct> -c <container> -o tableList blobs in a container.
az acr login -n <registry>Authenticate Docker against an Azure Container Registry.
az acr repository list -n <registry> -o tableList repos in an ACR.