Member-only story

Install & Configure Azure CLI

Kanan Rahimov
2 min readJul 28, 2019

--

This short tutorial covers topics like install Azure CLI, log in so you can use command via terminal and select account/subscription.

First, install Azure CLI:

brew update && brew install azure-cli

Then, log in to your Azure account by executing the following command:

az login

This command will open a browser window where you can sign to Azure. If the login was successful you will see a list of your current subscriptions.

[
{
"cloudName": "AzureCloud",
"id": "subscripion1-id",
"isDefault": true,
"name": "Pay-As-You-Go",
"state": "Enabled",
"tenantId": "tenant-id",
"user": {
"name": "your-account-id-or-email",
"type": "user"
}
},
{
"cloudName": "AzureCloud",
"id": "subscription2-id",
"isDefault": false,
"name": "Pay-As-You-Go",
"state": "Enabled",
"tenantId": "tenant-id",
"user": {
"name": "your-account-id-or-email",
"type": "user"
}
}
]

I have 2 subscriptions so for me it’s 2 items. You can output this data any time by typing az account list or az account list — output table for table output.

--

--

Kanan Rahimov
Kanan Rahimov

No responses yet