Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(core_project_factory): ignore create if default service account already exists #910

Merged
merged 3 commits into from
May 17, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions modules/core_project_factory/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -143,10 +143,11 @@ resource "google_project_default_service_accounts" "default_service_accounts" {
Default Service Account configuration
*****************************************/
resource "google_service_account" "default_service_account" {
count = var.create_project_sa ? 1 : 0
account_id = var.project_sa_name
display_name = "${var.name} Project Service Account"
project = google_project.main.project_id
count = var.create_project_sa ? 1 : 0
account_id = var.project_sa_name
display_name = "${var.name} Project Service Account"
project = google_project.main.project_id
create_ignore_already_exists = true
}

/**************************************************
Expand Down