terraform-google-modules/terraform-google-scheduled-function

Terraform apply always has an update

Closed this issue · 2 comments

When re-running the Terraform module multiple times, there is always something to update.

Here is the update in-place that Terraform wants to re-do everytime:

# module.slo.module.slo-cloud-function.module.pubsub_topic.google_pubsub_topic.topic will be updated in-place
  ~ resource "google_pubsub_topic" "topic" {
        id      = "projects/rnm-shared-slo-6c95/topics/slo-svc-pubsub-pubsub-ack"
        labels  = {}
        name    = "slo-svc-pubsub-pubsub-ack"
        project = "rnm-shared-slo-6c95"


      - message_storage_policy {
          - allowed_persistence_regions = [
              - "asia-east1",
              - "asia-east2",
              - "asia-northeast1",
              - "asia-northeast2",
              - "asia-south1",
              - "asia-southeast1",
              - "australia-southeast1",
              - "europe-north1",
              - "europe-west1",
              - "europe-west2",
              - "europe-west3",
              - "europe-west4",
              - "europe-west5",
              - "europe-west6",
              - "northamerica-northeast1",
              - "southamerica-east1",
              - "us-central1",
              - "us-central2",
              - "us-east1",
              - "us-east4",
              - "us-west1",
              - "us-west2",
            ] -> null
        }
    }

Maybe we can set a default for the allowed_persistence_regions list so that Terraform doesn't trigger an update everytime ?

Issue fixed in 2.18 version, in both "google-beta" and "google" providers.