diff --git a/products/memcache/api.yaml b/products/memcache/api.yaml index 636d38303f40..db7692d43e80 100644 --- a/products/memcache/api.yaml +++ b/products/memcache/api.yaml @@ -56,8 +56,7 @@ objects: - !ruby/object:Api::Type::String name: 'region' description: | - The name of the Memcache region of the instance. - required: true + The region of the Memcache instance. If it is not provided, the provider region is used. input: true url_param_only: true properties: diff --git a/products/memcache/terraform.yaml b/products/memcache/terraform.yaml index 85801e23b860..17142ddacf05 100644 --- a/products/memcache/terraform.yaml +++ b/products/memcache/terraform.yaml @@ -35,7 +35,7 @@ overrides: !ruby/object:Overrides::ResourceOverrides default_from_api: true is_set: true region: !ruby/object:Overrides::Terraform::PropertyOverride - ignore_read: true + default_from_api: true parameters: !ruby/object:Overrides::Terraform::PropertyOverride name: memcacheParameters diff --git a/products/tpu/api.yaml b/products/tpu/api.yaml index 4890d40fed03..25ec362224cd 100644 --- a/products/tpu/api.yaml +++ b/products/tpu/api.yaml @@ -55,8 +55,7 @@ objects: - !ruby/object:Api::Type::String # TODO: resourceref? name: 'zone' description: | - The GCP location for the TPU. - required: true + The GCP location for the TPU. If it is not provided, the provider zone is used. input: true url_param_only: true properties: diff --git a/products/tpu/terraform.yaml b/products/tpu/terraform.yaml index 24b6da832f20..ae50962c52b8 100644 --- a/products/tpu/terraform.yaml +++ b/products/tpu/terraform.yaml @@ -43,7 +43,7 @@ overrides: !ruby/object:Overrides::ResourceOverrides default_from_api: true diff_suppress_func: 'compareSelfLinkOrResourceName' zone: !ruby/object:Overrides::Terraform::PropertyOverride - ignore_read: true + default_from_api: true custom_code: !ruby/object:Provider::Terraform::CustomCode constants: 'templates/terraform/constants/tpu_node.erb' resource_definition: 'templates/terraform/resource_definition/tpu_node.erb' diff --git a/products/vpcaccess/api.yaml b/products/vpcaccess/api.yaml index 87b7caf91e35..ac2fa51a0379 100644 --- a/products/vpcaccess/api.yaml +++ b/products/vpcaccess/api.yaml @@ -57,8 +57,7 @@ objects: - !ruby/object:Api::Type::String name: 'region' description: | - Region where the VPC Access connector resides - required: true + Region where the VPC Access connector resides. If it is not provided, the provider region is used. input: true url_param_only: true properties: diff --git a/products/vpcaccess/terraform.yaml b/products/vpcaccess/terraform.yaml index fd81792c7481..c7c53a89fbd7 100644 --- a/products/vpcaccess/terraform.yaml +++ b/products/vpcaccess/terraform.yaml @@ -42,6 +42,8 @@ overrides: !ruby/object:Overrides::ResourceOverrides function: 'validation.IntBetween(200, 1000)' state: !ruby/object:Overrides::Terraform::PropertyOverride exclude: false + region: !ruby/object:Overrides::Terraform::PropertyOverride + default_from_api: true selfLink: !ruby/object:Overrides::Terraform::PropertyOverride ignore_read: true diff --git a/templates/terraform/examples/memcache_instance_basic.tf.erb b/templates/terraform/examples/memcache_instance_basic.tf.erb index e65a789e389f..7125625de563 100644 --- a/templates/terraform/examples/memcache_instance_basic.tf.erb +++ b/templates/terraform/examples/memcache_instance_basic.tf.erb @@ -22,7 +22,6 @@ resource "google_service_networking_connection" "private_service_connection" { resource "google_memcache_instance" "<%= ctx[:primary_resource_id] %>" { provider = google-beta name = "<%= ctx[:vars]["instance_name"] %>" - region = "us-central1" authorized_network = google_service_networking_connection.private_service_connection.network node_config { diff --git a/templates/terraform/examples/vpc_access_connector.tf.erb b/templates/terraform/examples/vpc_access_connector.tf.erb index 28118a7bb2a2..1a9e997c5400 100644 --- a/templates/terraform/examples/vpc_access_connector.tf.erb +++ b/templates/terraform/examples/vpc_access_connector.tf.erb @@ -1,6 +1,5 @@ resource "google_vpc_access_connector" "connector" { name = "<%= ctx[:vars]['name'] %>" - region = "us-central1" ip_cidr_range = "10.8.0.0/28" network = "default" }