-
Notifications
You must be signed in to change notification settings - Fork 545
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Give VPC Access Agent Service Account for Cloud Run permissions…
… on Shared VPC (#615) * Grant compute.networkUser role to Serverless VPC Access Service Agent * update comments
- Loading branch information
Showing
1 changed file
with
3 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -26,6 +26,7 @@ locals { | |
"dataproc.googleapis.com" : format("service-%[email protected]", local.service_project_number), | ||
"dataflow.googleapis.com" : format("service-%[email protected]", local.service_project_number), | ||
"composer.googleapis.com" : format("service-%[email protected]", local.service_project_number) | ||
"vpcaccess.googleapis.com" : format("service-%[email protected]", local.service_project_number) | ||
} | ||
gke_shared_vpc_enabled = contains(var.active_apis, "container.googleapis.com") | ||
composer_shared_vpc_enabled = contains(var.active_apis, "composer.googleapis.com") | ||
|
@@ -39,6 +40,8 @@ locals { | |
if "dataflow.googleapis.com" compute.networkUser role granted to dataflow service account for Dataflow on shared VPC subnets | ||
See: https://cloud.google.com/kubernetes-engine/docs/how-to/cluster-shared-vpc | ||
https://cloud.google.com/dataflow/docs/concepts/security-and-permissions#cloud_dataflow_service_account | ||
if "vpcaccess.googleapis.com" compute.networkUser role granted to Serverless VPC Access Service Agent on shared VPC subnets | ||
See: https://cloud.google.com/run/docs/configuring/connecting-shared-vpc#grant-permissions | ||
*****************************************/ | ||
resource "google_compute_subnetwork_iam_member" "service_shared_vpc_subnet_users" { | ||
provider = google-beta | ||
|