From 5e964c5ab96b9f418de8241d7677d07b699e30a3 Mon Sep 17 00:00:00 2001 From: drfaust92 Date: Sat, 7 Jan 2023 08:53:25 +0200 Subject: [PATCH 1/2] job iam --- mmv1/products/cloudrunv2/api.yaml | 5 +++++ mmv1/products/cloudrunv2/terraform.yaml | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/mmv1/products/cloudrunv2/api.yaml b/mmv1/products/cloudrunv2/api.yaml index 205d8c29787a..3ae32787d220 100644 --- a/mmv1/products/cloudrunv2/api.yaml +++ b/mmv1/products/cloudrunv2/api.yaml @@ -56,6 +56,11 @@ objects: error: !ruby/object:Api::OpAsync::Error path: "error" message: "message" + iam_policy: !ruby/object:Api::Resource::IamPolicy + method_name_separator: ':' + parent_resource_attribute: 'name' + base_url: projects/{{project}}/locations/{{location}}/jobs/{{name}} + import_format: ["projects/{{project}}/locations/{{location}}/jobs/{{name}}", "{{name}}"] parameters: - !ruby/object:Api::Type::String name: "location" diff --git a/mmv1/products/cloudrunv2/terraform.yaml b/mmv1/products/cloudrunv2/terraform.yaml index 7059b084873b..1d3bfe9c5d29 100644 --- a/mmv1/products/cloudrunv2/terraform.yaml +++ b/mmv1/products/cloudrunv2/terraform.yaml @@ -21,7 +21,7 @@ overrides: !ruby/object:Overrides::ResourceOverrides - !ruby/object:Provider::Terraform::Examples name: "cloudrunv2_job_basic" primary_resource_id: "default" - primary_resource_name: "fmt.Sprintf(\"tf-test-cloudrun-srv%s\", context[\"random_suffix\"])" + primary_resource_name: "fmt.Sprintf(\"tf-test-cloudrun-job%s\", context[\"random_suffix\"])" vars: cloud_run_job_name: "cloudrun-job" - !ruby/object:Provider::Terraform::Examples From bb87e712a62819112ab995ce37b70a6ec4bc1eaf Mon Sep 17 00:00:00 2001 From: drfaust92 Date: Sat, 7 Jan 2023 09:16:00 +0200 Subject: [PATCH 2/2] iam for service resource --- mmv1/products/cloudrunv2/api.yaml | 5 +++++ mmv1/products/cloudrunv2/terraform.yaml | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/mmv1/products/cloudrunv2/api.yaml b/mmv1/products/cloudrunv2/api.yaml index 3ae32787d220..2ac61268877b 100644 --- a/mmv1/products/cloudrunv2/api.yaml +++ b/mmv1/products/cloudrunv2/api.yaml @@ -674,6 +674,11 @@ objects: api: "https://cloud.google.com/run/docs/reference/rest/v2/projects.locations.services" description: | Service acts as a top-level container that manages a set of configurations and revision templates which implement a network service. Service exists to provide a singular abstraction which can be access controlled, reasoned about, and which encapsulates software lifecycle decisions such as rollout policy and team resource ownership. + iam_policy: !ruby/object:Api::Resource::IamPolicy + method_name_separator: ':' + parent_resource_attribute: 'name' + base_url: projects/{{project}}/locations/{{location}}/services/{{name}} + import_format: ["projects/{{project}}/locations/{{location}}/services/{{name}}", "{{name}}"] async: !ruby/object:Api::OpAsync operation: !ruby/object:Api::OpAsync::Operation path: "name" diff --git a/mmv1/products/cloudrunv2/terraform.yaml b/mmv1/products/cloudrunv2/terraform.yaml index 1d3bfe9c5d29..adfe5375161a 100644 --- a/mmv1/products/cloudrunv2/terraform.yaml +++ b/mmv1/products/cloudrunv2/terraform.yaml @@ -96,7 +96,7 @@ overrides: !ruby/object:Overrides::ResourceOverrides - !ruby/object:Provider::Terraform::Examples name: "cloudrunv2_service_basic" primary_resource_id: "default" - primary_resource_name: "fmt.Sprintf(\"tf-test-cloudrun-srv%s\", context[\"random_suffix\"])" + primary_resource_name: "fmt.Sprintf(\"tf-test-cloudrun-service%s\", context[\"random_suffix\"])" vars: cloud_run_service_name: "cloudrun-service" - !ruby/object:Provider::Terraform::Examples