Reputation: 21
I'm trying to deploy a function app (EP1), an App Service Environment (I1v2), and App Service Plans in Azure, targeting the East US region. I'm using the Azure portal, CLI, and Terraform, but I keep getting this error in my terraform console after running terraform apply. It is the same error in CLI and Wizard Portal:
│ Error: creating App Service Plan (Subscription: "<redacted>"
│ Resource Group Name: "rg_nam_ss_eus_<redacted>"
│ Server Farm Name: "asp-<redacted>-I1v2"): performing CreateOrUpdate: unexpected status 401 (401 Unauthorized) with response: {"Code":"Unauthorized","Message":"This region has quota of 0 instances for your subscription. Try selecting different region or SKU.","Target":null,"Details":[{"Message":"This region has quota of 0 instances for your subscription. Try selecting different region or SKU."},{"Code":"Unauthorized"},{"ErrorEntity":{"ExtendedCode":"52039","MessageTemplate":"{0}. Try selecting different region or SKU.","Parameters":["This region has quota of 0 instances for your subscription"],"Code":"Unauthorized","Message":"This region has quota of 0 instances for your subscription. Try selecting different region or SKU."}}],"Innererror":null}
│
│ with azurerm_service_plan.res-77,
│ on main.aztfexport.tf line 374, in resource "azurerm_service_plan" "res-77":
│ 374: resource "azurerm_service_plan" "res-77" {
│
│ creating App Service Plan (Subscription: "<redacted>"
│ Resource Group Name: "rg_nam_ss_eus_<redacted>"
│ Server Farm Name: "asp-<redacted>-I1v2"): performing CreateOrUpdate: unexpected status 401 (401 Unauthorized) with response:
│ {"Code":"Unauthorized","Message":"This region has quota of 0 instances for your subscription. Try selecting different region or
│ SKU.","Target":null,"Details":[{"Message":"This region has quota of 0 instances for your subscription. Try selecting different region or
│ SKU."},{"Code":"Unauthorized"},{"ErrorEntity":{"ExtendedCode":"52039","MessageTemplate":"{0}. Try selecting different region or
│ SKU.","Parameters":["This region has quota of 0 instances for your subscription"],"Code":"Unauthorized","Message":"This region has quota of 0
│ instances for your subscription. Try selecting different region or SKU."}}],"Innererror":null}
╵
╷
│ Error: creating App Service Plan (Subscription: "<redacted>"
│ Resource Group Name: "rg_nam_ss_eus_<redacted>"
│ Server Farm Name: "asp-<redacted>-fa-EP1"): performing CreateOrUpdate: unexpected status 401 (401 Unauthorized) with response: {"Code":"Unauthorized","Message":"This region has quota of 0 instances for your subscription. Try selecting different region or SKU.","Target":null,"Details":[{"Message":"This region has quota of 0 instances for your subscription. Try selecting different region or SKU."},{"Code":"Unauthorized"},{"ErrorEntity":{"ExtendedCode":"52039","MessageTemplate":"{0}. Try selecting different region or SKU.","Parameters":["This region has quota of 0 instances for your subscription"],"Code":"Unauthorized","Message":"This region has quota of 0 instances for your subscription. Try selecting different region or SKU."}}],"Innererror":null}
│
│ with azurerm_service_plan.res-78,
│ on main.aztfexport.tf line 389, in resource "azurerm_service_plan" "res-78":
│ 389: resource "azurerm_service_plan" "res-78" {
│
│ creating App Service Plan (Subscription: "<redacted>"
│ Resource Group Name: "rg_nam_ss_eus_<redacted>"
│ Server Farm Name: "asp-<redacted>-fa-EP1"): performing CreateOrUpdate: unexpected status 401 (401 Unauthorized) with response:
│ {"Code":"Unauthorized","Message":"This region has quota of 0 instances for your subscription. Try selecting different region or
│ SKU.","Target":null,"Details":[{"Message":"This region has quota of 0 instances for your subscription. Try selecting different region or
│ SKU."},{"Code":"Unauthorized"},{"ErrorEntity":{"ExtendedCode":"52039","MessageTemplate":"{0}. Try selecting different region or
│ SKU.","Parameters":["This region has quota of 0 instances for your subscription"],"Code":"Unauthorized","Message":"This region has quota of 0
│ instances for your subscription. Try selecting different region or SKU."}}],"Innererror":null}
This is our ASE terraform definition:
resource "azurerm_app_service_environment_v3" "res-75" {
internal_load_balancing_mode = "Web, Publishing"
name = local.ase_name
remote_debugging_enabled = true
resource_group_name = azurerm_resource_group.rg.name
subnet_id = "/subscriptions/${local.spoke_subscription_id}/resourceGroups/${local.spoke_rg_name}/providers/Microsoft.Network/virtualNetworks/${local.spoke_vnet_name}/subnets/${local.spoke_subnet_name_ase}"
allow_new_private_endpoint_connections = true
zone_redundant = false
cluster_setting {
name = "DisableTls1.0"
value = "1"
}
tags = {
Project = tostring(local.project_name)
}
}
We have registered almost all resource providers for the subscription, every resource is located in East US, we have requested quota increase for almost all compute stacks but we are using 0% of ALL quota except for the ones that say "0 out of 0" available or troubleshoot. We have been trying to deploy every day for the last 2 weeks, so it is not a momentary error. This is a new subscription, and we have no issues in any of our other subscriptions.
If anyone knows what quota we need to deploy two App Service Plans I1v2 or EP1, that would be great. I cannot find this info online so far. We have looked over our networking and can't find any issues.
Upvotes: 1
Views: 586
Reputation: 191
Following are the quota requirements of I1v2 and EP1
Probably, you are stuck on availing the I1v2 quota in my thought
Upvotes: 0
Reputation: 86
This is definitely a quota issue that can be resolved by deploying to another region or raising a support request to Azure for further support if you insist on deploying to said region
Upvotes: 0