Skip to content

Commit 957c25b

Browse files
committed
Feat: extend iam for firebase rules
1 parent 4da8d07 commit 957c25b

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

terraform/firebase.tf

+4-1
Original file line numberDiff line numberDiff line change
@@ -58,5 +58,8 @@ resource "google_firebaserules_ruleset" "basic" {
5858
}
5959

6060
project = var.PROJECT_ID
61-
depends_on = [google_firebase_project.default]
61+
depends_on = [
62+
google_firebase_project.default,
63+
google_project_iam_member.service_account_firebase_rules
64+
]
6265
}

terraform/iam.tf

+6
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,12 @@ resource "google_project_iam_member" "service_account_firebase_admin" {
88
member = "serviceAccount:${google_service_account.firebase.email}"
99
}
1010

11+
resource "google_project_iam_member" "service_account_firebase_rules" {
12+
project = var.PROJECT_ID
13+
role = "roles/firebaserules.admin"
14+
member = "serviceAccount:${google_service_account.firebase.email}"
15+
}
16+
1117
resource "google_project_iam_member" "service_account_storage_admin" {
1218
project = var.PROJECT_ID
1319
role = "roles/storage.admin"

0 commit comments

Comments
 (0)