terraform-provider-google icon indicating copy to clipboard operation
terraform-provider-google copied to clipboard

Documentation: type on google_compute_security_policy is misplaced

Open Freebios opened this issue 3 years ago • 0 comments

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment. If the issue is assigned to the "modular-magician" user, it is either in the process of being autogenerated, or is planned to be autogenerated soon. If the issue is assigned to a user, that user is claiming responsibility for the issue. If the issue is assigned to "hashibot", a community member has claimed the issue already.

Description

The documentation of the google_compute_security_policy resource on terraform.io is outdated / wrong.

The type of security policy is referenced under advanced_options_config block even though it should be used at the root of the resource.

The documentation seem to indicate to use the resource this way

resource "google_compute_security_policy" "policy" {
  name = "my-policy"

  advanced_options_config {
    type = "CLOUD_ARMOR_EDGE"
  }
}

But only the following works

resource "google_compute_security_policy" "policy" {
  name = "my-policy"

  type = "CLOUD_ARMOR_EDGE"
}

New or Affected Resource(s)

https://registry.terraform.io/providers/hashicorp/google/latest/docs/resources/compute_security_policy

Freebios avatar Sep 14 '22 15:09 Freebios