Skip to content

Commit

Permalink
Add service_account input to cloud_run
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewscwei committed Feb 21, 2023
1 parent cc9f5db commit 179bea5
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cloud_run/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ resource "google_cloud_run_service" "default" {

template {
spec {
service_account_name = var.service_account

containers {
image = var.container.image

Expand Down
7 changes: 7 additions & 0 deletions cloud_run/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,10 @@ variable "project_id" {
description = "ID of project to create resources in."
type = string
}

variable "service_account" {
default = null
description = "Email of the service account to associate with the Cloud Run instance."
nullable = true
type = string
}

0 comments on commit 179bea5

Please sign in to comment.