Connect to Azure Classic with PowerShell

Certain features in Azure can only be managed via PowerShell. Before you can start using the commands you need to install Azure PowerShell. Install it from the Microsoft link below :

http://aka.ms/webpi-azps

Once installed, launch an elevated PowerShell session and run the command

powershell
Add-AzureAccount

This will launch a Microsoft Web Login page. Login with your Microsoft credentials tied to your Azure tenant.

You are now connected to Azure. The first commands you will generally always type once connected is to select your subscription of which you want to administrate. You can list all the subscriptions under the Azure tenant with the command.

powershell
Get-AzureSubscription

You can now select the subscription that you want to use with the command

powershell
Set-AzureSubscription -SubscriptionName SubscriptionName

So in my example above I would use

powershell
Set-AzureSubscription -SubscriptionName "Free Trial"

You are now ready to go…..

Comments