Selecting Azure Subscription

Steps to select Azure Subscription

To select Azure subscription, as the first step,  Login to your computer and open up your Azure PowerShell and type,

Add-AzureAccount

Press Enter

Now you will see a popup, which will ask you to sign in to your Azure account. Enter your username(email address) and press ‘Continue’. Now you enter your password.

The below command will list all the subscriptions, that you have,

Get-AzureSubscription

To view the currently selected subscription, please execute the below command,

Get-AzureSubscription -Current

To select a subscription from the list of your subscriptions, please execute the below command,

Select-AzureSubscription –SubscriptionName ""

If you wish to set the selected the subscription as your default subscription, please add the switch -Default.

Select-AzureSubscription -SubscriptionName "" -Default

If you do not wish to have a default subscription, please execute the below command,

Set-AzureSubscription -NoDefaultSubscription

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.