The terraform plan results when you are using azurerm_application_gateway shows that it destroys then recreates the same configuration of its resources.
It sets all the values to → null, then later recreates the same resource
Here is an example of a listener being destroyed then recreated:
- http_listener {
- frontend_ip_configuration_id = "/subscriptions/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx/resourceGroups/example-rg/providers/Microsoft.Network/applicationGateways/example-agw/frontendIPConfigurations/example-agw-pip" -> null
- frontend_ip_configuration_name = "example-agw-pip" -> null
- frontend_port_id = "/subscriptions/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx/resourceGroups/example-rg/providers/Microsoft.Network/applicationGateways/example-agw/frontendPorts/port_80" -> null
- frontend_port_name = "port_80" -> null
- host_name = "www.example.com" -> null
- host_names = [] -> null
- id = "/subscriptions/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx/resourceGroups/example-rg/providers/Microsoft.Network/applicationGateways/example-agw/httpListeners/publicRedirect" -> null
- name = "publicRedirect" -> null
- protocol = "Http" -> null
- require_sni = false -> null
}
+ http_listener {
+ frontend_ip_configuration_id = (known after apply)
+ frontend_ip_configuration_name = "example-agw-pip"
+ frontend_port_id = (known after apply)
+ frontend_port_name = "port_80"
+ host_name = "www.example.com"
+ host_names = []
+ id = (known after apply)
+ name = "publicRedirect"
+ protocol = "Http"
+ ssl_certificate_id = (known after apply)
+ ssl_profile_id = (known after apply)
}
This happens for listeners, routing rules, probes, etc.