Table of Contents
Azure CLI Install using PowerShell
1
Invoke-WebRequest -Uri https://aka.ms/installazurecliwindows -OutFile .\AzureCLI.msi; Start-Process msiexec.exe -Wait -ArgumentList '/I AzureCLI.msi /quiet'; rm .\AzureCLI.msi
Login to Azure ClI
Login to Azure Cli
1
az login
The output of the command will be something like:
1
PS C:\Users\davidmarker> az login
You have logged in. Now let us find all the subscriptions to which you have access…
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
[
{
"cloudName": "AzureCloud",
"homeTenantId": "1x84x305-xxxx-4x10-x8x6-08xx0xx48xx6",
"id": "xxx1x7xx-9185-4xxx-xx5x-xx8b96x9xxx4",
"isDefault": true,
"managedByTenants": [],
"name": "davidmarker.net - Pay-As-You-Go",
"state": "Enabled",
"tenantId": "1x84x305-xxxx-4x10-x8x6-08xx0xx48xx6",
"user": {
"name": "azure@davidmarker.com",
"type": "user"
}
}
]
Login to Azure Cli with credentials
1
az login -u <username> -p <password>
The output of the command will be something like:
1
PS C:\Users\davidmarker> az login -u 'azure@davidmarker.com' -p ************
You have logged in. Now let us find all the subscriptions to which you have access…
{
"cloudName": "AzureCloud",
"homeTenantId": "1x84x305-xxxx-4x10-x8x6-08xx0xx48xx6",
"id": "xxx1x7xx-9185-4xxx-xx5x-xx8b96x9xxx4",
"isDefault": true,
"managedByTenants": [],
"name": "davidmarker.net - Pay-As-You-Go",
"state": "Enabled",
"tenantId": "1x84x305-xxxx-4x10-x8x6-08xx0xx48xx6",
"user": {
"name": "azure@davidmarker.com",
"type": "user"
}
}
]
https://aka.ms/devicelogin
https://shell.azure.com/
Log Off Azure Cli
1
az logout