AzCLI
Common Commands
Login without a sub
az login --allow-no-subscriptions
Logout of All Contexts
az logout
az account clear
Log into Specific Tenant
az login --tenant $tenant
Show All Subscriptions
az account list
Print all policies at all management groups to file
az account management-group list --query "[].{id:id,name:name}" -o tsv | while read -r mgid name; do
az policy assignment list --scope "$mgid" >> $name
done