1
0
Fork 0
forge/terraform/variables.tf
Jason Hall 15ea287728 add budget alert and nightly OS-update reboot
- $10/month project budget via google_billing_budget, alerts to admin_email
- forgejo-reboot.timer at 04:30 UTC applies staged COS updates
- relocate cloud-init scripts to /var/lib/google/forgejo (COS noexec on /var)
- runbook: updated zone, script paths, added "How updates work" section

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-07 20:35:58 -04:00

61 lines
1.5 KiB
HCL

variable "project_id" {
type = string
description = "GCP project ID"
}
variable "region" {
type = string
default = "us-central1"
description = "GCP region (use us-west1, us-central1, or us-east1 for the always-free e2-micro)"
}
variable "zone" {
type = string
default = "us-central1-a"
description = "GCP zone within region"
}
variable "domain" {
type = string
description = "Domain name for the Forgejo instance (e.g. git.example.com)"
}
variable "admin_email" {
type = string
description = "Google account that gets IAP SSH access and budget alert emails"
}
variable "billing_account" {
type = string
description = "Billing account ID (format: XXXXXX-XXXXXX-XXXXXX) for the budget alert"
}
variable "budget_amount_usd" {
type = number
default = 10
description = "Monthly budget in USD; alerts fire at 50%, 90%, 100% of this"
}
variable "forgejo_image" {
type = string
default = "codeberg.org/forgejo/forgejo:11"
description = "Forgejo container image, pinned to a major version"
}
variable "caddy_image" {
type = string
default = "caddy:2-alpine"
description = "Caddy container image, pinned to a major version"
}
variable "manage_dns" {
type = bool
default = false
description = "If true, manage an A record in Cloud DNS. Requires dns_managed_zone."
}
variable "dns_managed_zone" {
type = string
default = ""
description = "Cloud DNS managed zone name (only used when manage_dns = true)"
}