From 8900a36bcf060175e7933993f4133aec21647878 Mon Sep 17 00:00:00 2001 From: Modular Magician Date: Tue, 24 Aug 2021 14:26:53 +0000 Subject: [PATCH] set all of replication to ForceNew (#5124) Signed-off-by: Modular Magician --- .changelog/5124.txt | 4 ++++ google-beta/resource_secret_manager_secret.go | 6 ++++++ 2 files changed, 10 insertions(+) create mode 100644 .changelog/5124.txt diff --git a/.changelog/5124.txt b/.changelog/5124.txt new file mode 100644 index 0000000000..812ebfaa1c --- /dev/null +++ b/.changelog/5124.txt @@ -0,0 +1,4 @@ +```release-note:bug +secretmanager: fixed an issue where `replication` fields would not update in `google_secret_manager_secret` + +``` diff --git a/google-beta/resource_secret_manager_secret.go b/google-beta/resource_secret_manager_secret.go index 3395a5e02c..8baf3ff17c 100644 --- a/google-beta/resource_secret_manager_secret.go +++ b/google-beta/resource_secret_manager_secret.go @@ -54,12 +54,14 @@ after the Secret has been created.`, "automatic": { Type: schema.TypeBool, Optional: true, + ForceNew: true, Description: `The Secret will automatically be replicated without any restrictions.`, ExactlyOneOf: []string{"replication.0.automatic", "replication.0.user_managed"}, }, "user_managed": { Type: schema.TypeList, Optional: true, + ForceNew: true, Description: `The Secret will automatically be replicated without any restrictions.`, MaxItems: 1, Elem: &schema.Resource{ @@ -67,6 +69,7 @@ after the Secret has been created.`, "replicas": { Type: schema.TypeList, Required: true, + ForceNew: true, Description: `The list of Replicas for this Secret. Cannot be empty.`, MinItems: 1, Elem: &schema.Resource{ @@ -74,11 +77,13 @@ after the Secret has been created.`, "location": { Type: schema.TypeString, Required: true, + ForceNew: true, Description: `The canonical IDs of the location to replicate data. For example: "us-east1".`, }, "customer_managed_encryption": { Type: schema.TypeList, Optional: true, + ForceNew: true, Description: `Customer Managed Encryption for the secret.`, MaxItems: 1, Elem: &schema.Resource{ @@ -86,6 +91,7 @@ after the Secret has been created.`, "kms_key_name": { Type: schema.TypeString, Required: true, + ForceNew: true, Description: `Describes the Cloud KMS encryption key that will be used to protect destination secret.`, }, },