This was a frustrating error – trying to publish your VS web app to an Azure Website, gives a long-winded error message about regions and subscriptions…

image

 

The workaround – Change your default region settings

Step 1 – Check if windows powershell is installed

Get-Module PowerShellGet -list | Select-Object Name,Version,Path

Step 2 – Install Azure Powershell from the Windows PS command

Install-Module AzureRM

Step 3 – Run the following from Azure Powershell

  1. Login-AzureRmAccount // Enter credentials to correct to your subscription
  2. $resource = Get-AzureRmResource
  3. $resource | where { $_.ResourceType -eq ‘Microsoft.insights/autoscalesettings’ } | Remove-AzureRmResource
  4. $resource | where { $_.ResourceType -eq ‘Microsoft.insights/alertrules’ } | Remove-AzureRmResource

Anuj holds professional certifications in Google Cloud, AWS as well as certifications in Docker and App Performance Tools such as New Relic. He specializes in Cloud Security, Data Encryption and Container Technologies.

Initial Consultation

Anuj Varma – who has written posts on Anuj Varma, Hands-On Technology Architect, Clean Air Activist.