diff --git a/products/compute/terraform.yaml b/products/compute/terraform.yaml index df5de9c48bac..6e35de32bf10 100644 --- a/products/compute/terraform.yaml +++ b/products/compute/terraform.yaml @@ -435,7 +435,6 @@ overrides: !ruby/object:Overrides::ResourceOverrides pre_delete: templates/terraform/pre_delete/detach_disk.erb constants: templates/terraform/constants/disk.erb encoder: templates/terraform/encoders/disk.erb - extra_schema_entry: templates/terraform/extra_schema_entry/disk.erb decoder: templates/terraform/decoders/disk.erb resource_definition: templates/terraform/resource_definition/disk.erb docs: !ruby/object:Provider::Terraform::Docs diff --git a/templates/terraform/extra_schema_entry/backend_service.erb b/templates/terraform/extra_schema_entry/backend_service.erb deleted file mode 100644 index db1638f05310..000000000000 --- a/templates/terraform/extra_schema_entry/backend_service.erb +++ /dev/null @@ -1,20 +0,0 @@ -<%# The license inside this block applies to this file. - # Copyright 2018 Google Inc. - # Licensed under the Apache License, Version 2.0 (the "License"); - # you may not use this file except in compliance with the License. - # You may obtain a copy of the License at - # - # http://www.apache.org/licenses/LICENSE-2.0 - # - # Unless required by applicable law or agreed to in writing, software - # distributed under the License is distributed on an "AS IS" BASIS, - # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - # See the License for the specific language governing permissions and - # limitations under the License. --%> -"region": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - Removed: "region has been removed as it was never used. For internal load balancing, use google_compute_region_backend_service", -}, diff --git a/templates/terraform/extra_schema_entry/disk.erb b/templates/terraform/extra_schema_entry/disk.erb deleted file mode 100644 index 70b790775337..000000000000 --- a/templates/terraform/extra_schema_entry/disk.erb +++ /dev/null @@ -1,13 +0,0 @@ -"disk_encryption_key_raw": &schema.Schema{ - Type: schema.TypeString, - Optional: true, - ForceNew: true, - Sensitive: true, - Removed: "Use disk_encryption_key.raw_key instead.", -}, - -"disk_encryption_key_sha256": &schema.Schema{ - Type: schema.TypeString, - Computed: true, - Removed: "Use disk_encryption_key.sha256 instead.", -}, diff --git a/templates/terraform/extra_schema_entry/snapshot.erb b/templates/terraform/extra_schema_entry/snapshot.erb index 2b4a08020615..1d0b3ae6b0f9 100644 --- a/templates/terraform/extra_schema_entry/snapshot.erb +++ b/templates/terraform/extra_schema_entry/snapshot.erb @@ -16,29 +16,3 @@ Type: schema.TypeString, Computed: true, }, - -"snapshot_encryption_key_raw": { - Type: schema.TypeString, - Optional: true, - Sensitive: true, - Removed: "Use snapshot_encryption_key.raw_key instead.", -}, - -"snapshot_encryption_key_sha256": { - Type: schema.TypeString, - Computed: true, - Removed: "Use snapshot_encryption_key.sha256 instead.", -}, - -"source_disk_encryption_key_raw": { - Type: schema.TypeString, - Optional: true, - Sensitive: true, - Removed: "Use source_disk_encryption_key.raw_key instead.", -}, - -"source_disk_encryption_key_sha256": { - Type: schema.TypeString, - Computed: true, - Removed: "Use source_disk_encryption_key.sha256 instead.", -}, diff --git a/third_party/terraform/data_sources/data_source_google_service_account_key.go b/third_party/terraform/data_sources/data_source_google_service_account_key.go index 3f6206204557..227d69a7637b 100644 --- a/third_party/terraform/data_sources/data_source_google_service_account_key.go +++ b/third_party/terraform/data_sources/data_source_google_service_account_key.go @@ -36,12 +36,6 @@ func dataSourceGoogleServiceAccountKey() *schema.Resource { Type: schema.TypeString, Computed: true, }, - "service_account_id": { - Type: schema.TypeString, - Optional: true, - Computed: true, - Removed: "Please use name to specify full service account key path projects/{project}/serviceAccounts/{serviceAccount}/keys/{keyId}", - }, }, } } diff --git a/third_party/terraform/resources/resource_bigtable_instance.go b/third_party/terraform/resources/resource_bigtable_instance.go index 56d8f79d2dd7..8a5ba3976957 100644 --- a/third_party/terraform/resources/resource_bigtable_instance.go +++ b/third_party/terraform/resources/resource_bigtable_instance.go @@ -87,34 +87,6 @@ func resourceBigtableInstance() *schema.Resource { Computed: true, ForceNew: true, }, - - "cluster_id": { - Type: schema.TypeString, - Optional: true, - Computed: true, - Removed: "Use cluster instead.", - }, - - "zone": { - Type: schema.TypeString, - Optional: true, - Computed: true, - Removed: "Use cluster instead.", - }, - - "num_nodes": { - Type: schema.TypeInt, - Optional: true, - Computed: true, - Removed: "Use cluster instead.", - }, - - "storage_type": { - Type: schema.TypeString, - Optional: true, - Computed: true, - Removed: "Use cluster instead.", - }, }, } } diff --git a/third_party/terraform/resources/resource_cloudfunctions_function.go b/third_party/terraform/resources/resource_cloudfunctions_function.go index 54f0d4301744..641c50c2f778 100644 --- a/third_party/terraform/resources/resource_cloudfunctions_function.go +++ b/third_party/terraform/resources/resource_cloudfunctions_function.go @@ -212,27 +212,10 @@ func resourceCloudFunctionsFunction() *schema.Resource { Optional: true, }, - "trigger_bucket": { - Type: schema.TypeString, - Optional: true, - Computed: true, - Removed: "This field is removed. Use `event_trigger` instead.", - ConflictsWith: []string{"trigger_http", "trigger_topic"}, - }, - "trigger_http": { - Type: schema.TypeBool, - Optional: true, - ForceNew: true, - ConflictsWith: []string{"trigger_bucket", "trigger_topic"}, - }, - - "trigger_topic": { - Type: schema.TypeString, - Optional: true, - Computed: true, - Removed: "This field is removed. Use `event_trigger` instead.", - ConflictsWith: []string{"trigger_http", "trigger_bucket"}, + Type: schema.TypeBool, + Optional: true, + ForceNew: true, }, "event_trigger": { diff --git a/third_party/terraform/resources/resource_compute_instance.go b/third_party/terraform/resources/resource_compute_instance.go index 0eb67fba1196..5cd5867a9fa8 100644 --- a/third_party/terraform/resources/resource_compute_instance.go +++ b/third_party/terraform/resources/resource_compute_instance.go @@ -216,12 +216,6 @@ func resourceComputeInstance() *schema.Resource { ValidateFunc: validation.StringInSlice([]string{"PREMIUM", "STANDARD"}, false), }, - "assigned_nat_ip": { - Type: schema.TypeString, - Computed: true, - Removed: "Use network_interface.access_config.nat_ip instead.", - }, - "public_ptr_domain_name": { Type: schema.TypeString, Optional: true, @@ -247,14 +241,6 @@ func resourceComputeInstance() *schema.Resource { }, }, }, - - "address": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - Computed: true, - Removed: "Please use network_ip", - }, }, }, }, @@ -328,72 +314,6 @@ func resourceComputeInstance() *schema.Resource { Default: false, }, - "disk": { - Type: schema.TypeList, - Optional: true, - ForceNew: true, - Removed: "Use boot_disk, scratch_disk, and attached_disk instead", - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - // TODO(mitchellh): one of image or disk is required - - "disk": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - }, - - "image": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - }, - - "type": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - }, - - "scratch": { - Type: schema.TypeBool, - Optional: true, - ForceNew: true, - }, - - "auto_delete": { - Type: schema.TypeBool, - Optional: true, - Default: true, - ForceNew: true, - }, - - "size": { - Type: schema.TypeInt, - Optional: true, - ForceNew: true, - }, - - "device_name": { - Type: schema.TypeString, - Optional: true, - }, - - "disk_encryption_key_raw": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - Sensitive: true, - }, - - "disk_encryption_key_sha256": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, - "enable_display": { Type: schema.TypeBool, Optional: true, diff --git a/third_party/terraform/resources/resource_compute_instance_template.go b/third_party/terraform/resources/resource_compute_instance_template.go index 3143f056ac35..b3cba11e3666 100644 --- a/third_party/terraform/resources/resource_compute_instance_template.go +++ b/third_party/terraform/resources/resource_compute_instance_template.go @@ -168,13 +168,6 @@ func resourceComputeInstanceTemplate() *schema.Resource { ForceNew: true, }, - "automatic_restart": { - Type: schema.TypeBool, - Optional: true, - ForceNew: true, - Removed: "Use 'scheduling.automatic_restart' instead.", - }, - "can_ip_forward": { Type: schema.TypeBool, Optional: true, @@ -270,11 +263,6 @@ func resourceComputeInstanceTemplate() *schema.Resource { Computed: true, ValidateFunc: validation.StringInSlice([]string{"PREMIUM", "STANDARD"}, false), }, - "assigned_nat_ip": { - Type: schema.TypeString, - Computed: true, - Removed: "Use network_interface.access_config.nat_ip instead.", - }, }, }, }, @@ -299,24 +287,10 @@ func resourceComputeInstanceTemplate() *schema.Resource { }, }, }, - - "address": { - Type: schema.TypeString, - Computed: true, - Optional: true, - Removed: "Please use network_ip", - }, }, }, }, - "on_host_maintenance": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - Removed: "Use 'scheduling.on_host_maintenance' instead.", - }, - "project": { Type: schema.TypeString, Optional: true, diff --git a/third_party/terraform/resources/resource_dataproc_cluster.go.erb b/third_party/terraform/resources/resource_dataproc_cluster.go.erb index 556ae53c7b4e..75dcbceee89f 100644 --- a/third_party/terraform/resources/resource_dataproc_cluster.go.erb +++ b/third_party/terraform/resources/resource_dataproc_cluster.go.erb @@ -91,14 +91,6 @@ func resourceDataprocCluster() *schema.Resource { Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "delete_autogen_bucket": { - Type: schema.TypeBool, - Optional: true, - Default: false, - Removed: "If you need a bucket that can be deleted, please create" + - "a new one and set the `staging_bucket` field", - }, - "staging_bucket": { Type: schema.TypeString, Optional: true, diff --git a/third_party/terraform/resources/resource_endpoints_service.go b/third_party/terraform/resources/resource_endpoints_service.go index 0411a050c704..b1fd24584154 100644 --- a/third_party/terraform/resources/resource_endpoints_service.go +++ b/third_party/terraform/resources/resource_endpoints_service.go @@ -35,12 +35,6 @@ func resourceEndpointsService() *schema.Resource { Type: schema.TypeString, Optional: true, }, - "protoc_output": { - Type: schema.TypeString, - Optional: true, - Computed: true, - Removed: "Please use protoc_output_base64 instead.", - }, "protoc_output_base64": { Type: schema.TypeString, Optional: true, diff --git a/third_party/terraform/resources/resource_google_project.go b/third_party/terraform/resources/resource_google_project.go index 5e03f413f2f3..a3d98ff81a93 100644 --- a/third_party/terraform/resources/resource_google_project.go +++ b/third_party/terraform/resources/resource_google_project.go @@ -72,17 +72,6 @@ func resourceGoogleProject() *schema.Resource { Computed: true, StateFunc: parseFolderId, }, - "policy_data": { - Type: schema.TypeString, - Optional: true, - Computed: true, - Removed: "Use the 'google_project_iam_policy' resource to define policies for a Google Project", - }, - "policy_etag": { - Type: schema.TypeString, - Computed: true, - Removed: "Use the the 'google_project_iam_policy' resource to define policies for a Google Project", - }, "number": { Type: schema.TypeString, Computed: true, @@ -96,109 +85,6 @@ func resourceGoogleProject() *schema.Resource { Optional: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "app_engine": { - Type: schema.TypeList, - Elem: appEngineResource(), - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, - }, - } -} - -func appEngineResource() *schema.Resource { - return &schema.Resource{ - Schema: map[string]*schema.Schema{ - "auth_domain": { - Type: schema.TypeString, - Optional: true, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, - "location_id": { - Type: schema.TypeString, - Optional: true, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, - "serving_status": { - Type: schema.TypeString, - Optional: true, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, - "feature_settings": { - Type: schema.TypeList, - Optional: true, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - Elem: appEngineFeatureSettingsResource(), - }, - "name": { - Type: schema.TypeString, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, - "url_dispatch_rule": { - Type: schema.TypeList, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - Elem: appEngineURLDispatchRuleResource(), - }, - "code_bucket": { - Type: schema.TypeString, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, - "default_hostname": { - Type: schema.TypeString, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, - "default_bucket": { - Type: schema.TypeString, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, - "gcr_domain": { - Type: schema.TypeString, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, - }, - } -} - -func appEngineURLDispatchRuleResource() *schema.Resource { - return &schema.Resource{ - Schema: map[string]*schema.Schema{ - "domain": { - Type: schema.TypeString, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, - "path": { - Type: schema.TypeString, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, - "service": { - Type: schema.TypeString, - Computed: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, - }, - } -} - -func appEngineFeatureSettingsResource() *schema.Resource { - return &schema.Resource{ - Schema: map[string]*schema.Schema{ - "split_health_checks": { - Type: schema.TypeBool, - Optional: true, - Removed: "This field has been removed. Use the google_app_engine_application resource instead.", - }, }, } } @@ -306,10 +192,6 @@ func resourceGoogleProjectRead(d *schema.ResourceData, meta interface{}) error { d.Set("name", p.Name) d.Set("labels", p.Labels) - // We get app_engine.#: "" => "" without this set - // Remove when app_engine field is removed from schema completely - d.Set("app_engine", nil) - if p.Parent != nil { switch p.Parent.Type { case "organization": diff --git a/third_party/terraform/resources/resource_google_project_iam_policy.go.erb b/third_party/terraform/resources/resource_google_project_iam_policy.go.erb index c2c48191adca..4ece61ad2f11 100644 --- a/third_party/terraform/resources/resource_google_project_iam_policy.go.erb +++ b/third_party/terraform/resources/resource_google_project_iam_policy.go.erb @@ -35,21 +35,6 @@ func resourceGoogleProjectIamPolicy() *schema.Resource { Type: schema.TypeString, Computed: true, }, - "authoritative": { - Removed: "The authoritative field was removed. To ignore changes not managed by Terraform, use google_project_iam_binding and google_project_iam_member instead. See https://www.terraform.io/docs/providers/google/r/google_project_iam.html for more information.", - Type: schema.TypeBool, - Optional: true, - }, - "restore_policy": { - Removed: "This field was removed alongside the authoritative field. To ignore changes not managed by Terraform, use google_project_iam_binding and google_project_iam_member instead. See https://www.terraform.io/docs/providers/google/r/google_project_iam.html for more information.", - Type: schema.TypeString, - Computed: true, - }, - "disable_project": { - Removed: "This field was removed alongside the authoritative field. Use lifecycle.prevent_destroy instead.", - Type: schema.TypeBool, - Optional: true, - }, }, } } diff --git a/third_party/terraform/resources/resource_google_service_account.go b/third_party/terraform/resources/resource_google_service_account.go index c5f16ded01eb..d2a294b99965 100644 --- a/third_party/terraform/resources/resource_google_service_account.go +++ b/third_party/terraform/resources/resource_google_service_account.go @@ -51,11 +51,6 @@ func resourceGoogleServiceAccount() *schema.Resource { Optional: true, ForceNew: true, }, - "policy_data": { - Type: schema.TypeString, - Optional: true, - Removed: "Use the 'google_service_account_iam_policy' resource to define policies for a service account", - }, }, } } diff --git a/third_party/terraform/resources/resource_storage_bucket.go b/third_party/terraform/resources/resource_storage_bucket.go index 683cd690a246..a2edfa1658b5 100644 --- a/third_party/terraform/resources/resource_storage_bucket.go +++ b/third_party/terraform/resources/resource_storage_bucket.go @@ -82,13 +82,6 @@ func resourceStorageBucket() *schema.Resource { }, }, - "predefined_acl": { - Type: schema.TypeString, - Removed: "Please use resource \"storage_bucket_acl.predefined_acl\" instead.", - Optional: true, - ForceNew: true, - }, - "project": { Type: schema.TypeString, Optional: true, diff --git a/third_party/terraform/resources/resource_storage_bucket_object.go b/third_party/terraform/resources/resource_storage_bucket_object.go index 31a000ecdbb6..96c0a6b7bfec 100644 --- a/third_party/terraform/resources/resource_storage_bucket_object.go +++ b/third_party/terraform/resources/resource_storage_bucket_object.go @@ -85,13 +85,6 @@ func resourceStorageBucketObject() *schema.Resource { Computed: true, }, - "predefined_acl": { - Type: schema.TypeString, - Removed: "Please use resource \"storage_object_acl.predefined_acl\" instead.", - Optional: true, - ForceNew: true, - }, - "source": { Type: schema.TypeString, Optional: true,