An overview of all the commands from the lates AZ Cli

Go to this website

List of your subscrptions

az account list --output table

Set current suscription

az account set --subscription "My Subscription"

Create container instance group from yaml file

az container create --resource-group My-Resource-Group --file my-deploy-file.yaml

Get logs from the container

container logs --resource-group My-Resource-Group --name My-Container-Group-name --container-name My-Container-Name

Log into a container from then az cli

az container exec --resource-group My-Resource-Group --name My-Container-Group-name --container-name My-Container-Nam --exec-command "/bin/bash"

Show container in a Container group

az container show --resource-group My-Resource-Group --name My-Container-Group-name --output table

List resource groups in a subscription

az group list [--subscription]
              [--tag]

Get access to with kubectl to cluster in azure

az aks get-credentials --resource-group myResourceGroup --name myAKSCluster

Get access credentials for a managed Kubernetes cluster. (autogenerated)

az aks get-credentials --name MyManagedCluster --resource-group MyResourceGroup

Login to an Azure Container Registry

az acr login --name <acrName>

Find which ad groups you are member of

 az ad user get-member-groups --id user@domain.com --query "[].displayName" -o tsv
 # or if you want to find a special entry
  az ad user get-member-groups --id user@domain.com --query "[].displayName" -o tsv | grep xxx