diff --git a/google/resource_compute_firewall.go b/google/resource_compute_firewall.go index e18bddfc576..07e929b8392 100644 --- a/google/resource_compute_firewall.go +++ b/google/resource_compute_firewall.go @@ -100,7 +100,7 @@ specifies a protocol and port-range tuple that describes a permitted connection.`, Elem: computeFirewallAllowSchema(), Set: resourceComputeFirewallRuleHash, - ExactlyOneOf: []string{"allow", "deny"}, + AtLeastOneOf: []string{"allow", "deny"}, }, "deny": { Type: schema.TypeSet, @@ -109,7 +109,7 @@ connection.`, a protocol and port-range tuple that describes a denied connection.`, Elem: computeFirewallDenySchema(), Set: resourceComputeFirewallRuleHash, - ExactlyOneOf: []string{"allow", "deny"}, + AtLeastOneOf: []string{"allow", "deny"}, }, "description": { Type: schema.TypeString, diff --git a/google/resource_compute_health_check.go b/google/resource_compute_health_check.go index 67b4bf8568c..69fb0b1b156 100644 --- a/google/resource_compute_health_check.go +++ b/google/resource_compute_health_check.go @@ -237,7 +237,7 @@ can only be ASCII.`, }, }, }, - ExactlyOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, + AtLeastOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, }, "http_health_check": { Type: schema.TypeList, @@ -316,7 +316,7 @@ can only be ASCII.`, }, }, }, - ExactlyOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, + AtLeastOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, }, "https_health_check": { Type: schema.TypeList, @@ -395,7 +395,7 @@ can only be ASCII.`, }, }, }, - ExactlyOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, + AtLeastOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, }, "ssl_health_check": { Type: schema.TypeList, @@ -467,7 +467,7 @@ can only be ASCII.`, }, }, }, - ExactlyOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, + AtLeastOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, }, "tcp_health_check": { Type: schema.TypeList, @@ -539,7 +539,7 @@ can only be ASCII.`, }, }, }, - ExactlyOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, + AtLeastOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, }, "timeout_sec": { Type: schema.TypeInt, diff --git a/google/resource_compute_region_health_check.go b/google/resource_compute_region_health_check.go index 1b521dedb44..953d5d8737f 100644 --- a/google/resource_compute_region_health_check.go +++ b/google/resource_compute_region_health_check.go @@ -154,7 +154,7 @@ can only be ASCII.`, }, }, }, - ExactlyOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, + AtLeastOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, }, "http_health_check": { Type: schema.TypeList, @@ -233,7 +233,7 @@ can only be ASCII.`, }, }, }, - ExactlyOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, + AtLeastOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, }, "https_health_check": { Type: schema.TypeList, @@ -312,7 +312,7 @@ can only be ASCII.`, }, }, }, - ExactlyOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, + AtLeastOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, }, "region": { Type: schema.TypeString, @@ -393,7 +393,7 @@ can only be ASCII.`, }, }, }, - ExactlyOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, + AtLeastOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, }, "tcp_health_check": { Type: schema.TypeList, @@ -465,7 +465,7 @@ can only be ASCII.`, }, }, }, - ExactlyOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, + AtLeastOneOf: []string{"http_health_check", "https_health_check", "http2_health_check", "tcp_health_check", "ssl_health_check"}, }, "timeout_sec": { Type: schema.TypeInt, diff --git a/google/resource_google_organization_policy.go b/google/resource_google_organization_policy.go index 939fda2caf4..5d34c46a864 100644 --- a/google/resource_google_organization_policy.go +++ b/google/resource_google_organization_policy.go @@ -40,10 +40,12 @@ var schemaOrganizationPolicy = map[string]*schema.Schema{ Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "allow": { - Type: schema.TypeList, - Optional: true, - MaxItems: 1, - ExactlyOneOf: []string{"list_policy.0.allow", "list_policy.0.deny"}, + Type: schema.TypeList, + Optional: true, + MaxItems: 1, + // TODO(terraform-providers/terraform-provider-google#5193): Change back to exactly_one_of + // once hashicorp/terraform-plugin-sdk#280 is fixed + AtLeastOneOf: []string{"list_policy.0.allow", "list_policy.0.deny"}, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "all": { @@ -63,10 +65,12 @@ var schemaOrganizationPolicy = map[string]*schema.Schema{ }, }, "deny": { - Type: schema.TypeList, - Optional: true, - MaxItems: 1, - ExactlyOneOf: []string{"list_policy.0.allow", "list_policy.0.deny"}, + Type: schema.TypeList, + Optional: true, + MaxItems: 1, + // TODO(terraform-providers/terraform-provider-google#5193): Change back to exactly_one_of + // once hashicorp/terraform-plugin-sdk#280 is fixed + AtLeastOneOf: []string{"list_policy.0.allow", "list_policy.0.deny"}, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "all": {