add new secrets

This commit is contained in:
sirius0xdev 2026-03-22 19:24:53 +00:00
commit 8b8ca5fe9e
10 changed files with 84 additions and 19 deletions

View file

@ -40,3 +40,12 @@ resource "google_service_account_iam_binding" "workload_identity_binding" {
output "gcp_sa_email" {
value = google_service_account.cnpg_backup_sa.email
}
resource "google_service_account_iam_member" "token_creator_binding" {
service_account_id = google_service_account.cnpg_backup_sa.name
role = "roles/iam.serviceAccountTokenCreator"
# This allows the GSA to generate tokens for itself when called by the pod
member = "serviceAccount:${google_service_account.cnpg_backup_sa.email}"
}