diff --git a/products/compute/terraform.yaml b/products/compute/terraform.yaml index 779c06ee5ee5..491db2395794 100644 --- a/products/compute/terraform.yaml +++ b/products/compute/terraform.yaml @@ -918,7 +918,6 @@ overrides: !ruby/object:Overrides::ResourceOverrides custom_code: !ruby/object:Provider::Terraform::CustomCode post_create: templates/terraform/post_create/compute_network_delete_default_route.erb extra_schema_entry: templates/terraform/extra_schema_entry/network.erb - encoder: templates/terraform/encoders/network.erb NetworkEndpoint: !ruby/object:Overrides::Terraform::ResourceOverride id_format: "{{project}}/{{zone}}/{{network_endpoint_group}}/{{instance}}/{{ip_address}}/{{port}}" mutex: networkEndpoint/{{project}}/{{zone}}/{{network_endpoint_group}} diff --git a/templates/terraform/encoders/network.erb b/templates/terraform/encoders/network.erb deleted file mode 100644 index e5e725c1ed67..000000000000 --- a/templates/terraform/encoders/network.erb +++ /dev/null @@ -1,5 +0,0 @@ -if _, ok := d.GetOk("ipv4_range"); !ok { - obj["autoCreateSubnetworks"] = d.Get("auto_create_subnetworks") -} - -return obj, nil diff --git a/templates/terraform/extra_schema_entry/network.erb b/templates/terraform/extra_schema_entry/network.erb index b69aa20b0079..a47523c01cca 100644 --- a/templates/terraform/extra_schema_entry/network.erb +++ b/templates/terraform/extra_schema_entry/network.erb @@ -14,6 +14,6 @@ -%> "ipv4_range": { Type: schema.TypeString, - Optional: true, + Computed: true, Removed: "Legacy Networks are deprecated and you will no longer be able to create them using this field from Feb 1, 2020 onwards.", }, \ No newline at end of file diff --git a/third_party/terraform/website/docs/version_3_upgrade.html.markdown b/third_party/terraform/website/docs/version_3_upgrade.html.markdown index 767b6250930a..7a8e35debfbf 100644 --- a/third_party/terraform/website/docs/version_3_upgrade.html.markdown +++ b/third_party/terraform/website/docs/version_3_upgrade.html.markdown @@ -134,7 +134,7 @@ Use `location` instead. ### `ipv4_range` is now removed -Legacy Networks are deprecated and you will no longer be able to create them +Legacy Networks are removed and you will no longer be able to create them using this field from Feb 1, 2020 onwards. ## Resource: `google_compute_network_peering`