# Generated by tools/hardened.py from ../t1. Edit t1 or the script; this file is regenerated. variable "project_id" { description = "Project containing the pool, the service account, and the resources it deploys to." type = string } variable "repository" { description = "The GitHub repository allowed to sign in, as org/repo." type = string validation { condition = can(regex("^[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+$", var.repository)) error_message = "Give one repository as org/repo, with no wildcard." } } variable "allowed_subjects" { description = "GitHub token subjects allowed to sign in. repo:org/repo:ref:refs/heads/main is one branch; repo:org/repo:environment:production is one deployment environment, which can require a reviewer in GitHub." type = list(string) validation { condition = length(var.allowed_subjects) > 0 && alltrue([for s in var.allowed_subjects : can(regex("^repo:[^*]+/[^*]+:", s))]) error_message = "Name at least one subject, each starting repo:org/repo: with no wildcard in the organisation or repository." } } variable "roles" { description = "Project roles the service account needs, and nothing more." type = list(string) default = [] } variable "gke_namespace" { description = "A GKE namespace whose Kubernetes service account may act as this service account through GKE Workload Identity. Leave empty to skip." type = string default = "" } variable "gke_service_account" { description = "That Kubernetes service account's name." type = string default = "app" } variable "owner" { description = "Label contract: accountable team. Lowercase, because labels must be." type = string default = "security-engineering" } variable "environment" { description = "Label contract: environment." type = string default = "prod" } variable "extra_labels" { description = "Additional labels merged over the contract." type = map(string) default = {} }