Open
Description
Terraform Version
Terraform v1.7.2
on darwin_arm64
- provider registry.terraform.io/hashicorp/google v5.25.0
Affected Resource(s)
google_compute_security_policy
Terraform Configuration
resource "google_compute_security_policy" "policy" {
name = var.policy_name
description = var.policy_description
type = "CLOUD_ARMOR"
project = var.project
adaptive_protection_config {
layer_7_ddos_defense_config {
enable = true
}
}
}
Expected Behavior
terraform plan should not update the resource as there are no changes
Actual Behavior
I have imported an existing security policy. When I run terraform plan
, I can see that terraform wants to add a rule_visibility
field even though it's optional according to the documentation:
$ terraform plan
...
~ adaptive_protection_config {
~ layer_7_ddos_defense_config {
+ rule_visibility = "STANDARD"
# (1 unchanged attribute hidden)
}
}
...
Plan: 0 to add, 1 to change, 0 to destroy.