CiscoDevNet / terraform-provider-aci

Terraform Cisco ACI provider
https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs
Mozilla Public License 2.0
88 stars 100 forks source link

Allow setting an empty annotation at the provider level to disable default annotation #1155

Closed danischm closed 7 months ago

danischm commented 7 months ago

Community Note

Description

With the recent change to allow setting an annotation globally, it would be great to allow setting it to an empty string to disable the default annotation:

provider "aci" {
  annotation = ""
}

Doing the same at the resource level with the aci_rest_managed resource already works:

resource "aci_rest_managed" "example_tenant" {
  dn         = "uni/tn-EXAMPLE_TENANT"
  class_name = "fvTenant"
  annotation = ""
  content = {
    name  = "EXAMPLE_TENANT"
    descr = "Example description"
  }
}

With the following plan output:

  # aci_rest_managed.example_tenant will be created
  + resource "aci_rest_managed" "example_tenant" {
      + class_name = "fvTenant"
      + content    = {
          + "descr" = "Example description"
          + "name"  = "EXAMPLE_TENANT"
        }
      + dn         = "uni/tn-EXAMPLE_TENANT"
      + id         = (known after apply)
    }