Advanced Search
Search Results
502 total results found
List available modules
Get-Module -ListAvailable
Get authenticated in Powershell
Connect-AzAccount %USERNAME
List commands in a module
Get-Command -Module <module name>
List functions in a module
Get-Command -Module <module name> -Type Function
Powershell
Authenticate via the CLI
Run this command to get authenticated: az login This will result in a web browser opening, or a URL prompt. Navigating to this url will prompt you for a code, which you’ve been provided in the command line. Paste it in, click next, and select the proper acco...
Debian Distros
List subscriptions for authenticated account
az account list
Get tenant id
az account list | jq '.[].tenantId'
Get subscription id
az cli: az account list | jq '.[].id' Powershell: Get-AzSubscription Resources:Powershell docsClI docs
List tenants
az account tenant list
List Resource Groups by name
az group list | jq -r '.[].name' Resource: https://docs.microsoft.com/en-us/cli/azure/group?view=azure-cli-latest
Set Subscription
az cli: az account set -s <name or id> Powershell: Set-AzureSubscription -Id [Subscription ID] Resources:https://powerzure.readthedocs.io/en/latest/Requirements/requirements.htmlhttps://stackoverflow.com/questions/38475104/azure-cli-how-to-change-subscript...
List all VMs
az vm list Resource: https://docs.microsoft.com/en-us/cli/azure/vm?view=azure-cli-latest
Mail Server IP Ranges
General
List all storage accounts and output in a table format: az storage account list -o table List all storage accounts and get storage account names: az storage account list -o json | jq -r '.[].name' You can assign one of the account names to an env var if yo...
Get storage keys
If you set the env var: az storage account keys list -n $AZURE_STORAGE_ACCOUNT You can assign one of the keys to an env var if you’d like: export AZURE_STORAGE_KEY='<your key from the output of the previous command>'