Error during deployment of resource – Subscription is not registered in region–error while publishing to Azure Websites or Azure API Apps
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…
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
- Login-AzureRmAccount // Enter credentials to correct to your subscription
- $resource = Get-AzureRmResource
- $resource | where { $_.ResourceType -eq ‘Microsoft.insights/autoscalesettings’ } | Remove-AzureRmResource
- $resource | where { $_.ResourceType -eq ‘Microsoft.insights/alertrules’ } | Remove-AzureRmResource
Leave a Reply