Open Aeternax opened 2 years ago
thanks for raising this issue. Per the doc descirption, seems the section ApplicationGatewayWebApplicationFirewallPolicies is expected.
This is a bug in the Azure portal, not the AzureRM provider. The resource JSON correctly lists the resource id with a capitalized A.
TF version: 1.1.7 azurerm version: 3.0.1 (also at least 2.99 and 2.85)
Command run:
terraform import azurerm_web_application_firewall_policy.firewall /subscriptions/....................../resourceGroups/XXXXXXXXXXXXXXXXXXXXX-RSG/providers/Microsoft.Network/applicationGatewayWebApplicationFirewallPolicies/yyyyyyyyyyyyyyy
Problem encountered:
Error: ID was missing the
ApplicationGatewayWebApplicationFirewallPolicies
element │ │ with azurerm_web_application_firewall_policy.firewall, │ on firewall.tf line 1, in resource "azurerm_web_application_firewall_policy" "firewall": │ 1: resource "azurerm_web_application_firewall_policy" "firewall" {Workaround:
Making capital A on ApplicationGatewayWebApplicationFirewallPolicies. The azure portal returns the ID with a lowercase a.
On at least azurerm version 2.67 the import "succeeded" but will largely be empty.