Skip to content

Commit fe3cded

Browse files
committed
docs(infra): clarify terraform.tfvars collaboration options
Document 3 collaboration patterns in terraform.tfvars.example: - Option A: Terraform Cloud (shared state, team) - Option B: Local state (own infra, isolation) - Option C: Multi-environment (per-person dev/staging) Add instructions for per-person environment customization.
1 parent 2c2efeb commit fe3cded

1 file changed

Lines changed: 42 additions & 5 deletions

File tree

infra/terraform/terraform.tfvars.example

Lines changed: 42 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,42 @@
55
# ============================================================
66
# terraform.tfvars is .gitignore'd — keep secrets out of git.
77
#
8-
# If you are using Terraform Cloud, set the variables in the
9-
# workspace Variables tab instead — Terraform Cloud will pass
10-
# them in, and terraform.tfvars is ignored. The two are NOT
11-
# loaded together.
8+
# HOW THIS WORKS:
9+
# This file is a TEMPLATE. Each developer fills in their OWN
10+
# tokens and gets their OWN infrastructure. Nobody shares
11+
# secrets — everyone creates their own Supabase project,
12+
# Vercel project, and DNS records.
13+
#
14+
# After filling in your values, run:
15+
# cd infra/terraform
16+
# terraform init
17+
# terraform apply
18+
#
19+
# To see your generated secrets (DB password, API keys):
20+
# terraform output -raw supabase_db_password
21+
# terraform output -raw supabase_anon_key
22+
# terraform output -raw supabase_service_role_key
23+
#
24+
# OPTION A — Terraform Cloud (shared state, team collaboration):
25+
# If using Terraform Cloud, set variables in the workspace
26+
# Variables tab instead. terraform.tfvars is ignored.
27+
# Both the .tfvars and the remote state are NOT in this repo.
28+
#
29+
# OPTION B — Local state (own infra, complete isolation):
30+
# Fill in this file with YOUR tokens. You get your own
31+
# Supabase project, Vercel project, etc. No sharing needed.
32+
# The state file (.terraform.tfstate) lives locally on YOUR
33+
# machine — it holds all generated secrets (DB password, etc.)
34+
# ⚠️ BACK UP your terraform.tfstate! If you lose it, you
35+
# lose access to your generated DB password and must reset
36+
# it in the Supabase dashboard manually.
37+
#
38+
# OPTION C — Multi-environment (dev/staging per person):
39+
# Each person changes `frontend_domain` and project names to
40+
# create their own isolated environment. Example:
41+
# frontend_domain = "senzen-jane.pantorn.site"
42+
# vercel_project_name = "senzen-jane"
43+
# supabase_project_name = "senzen-jane"
1244
# ============================================================
1345

1446
# Terraform Cloud
@@ -39,7 +71,12 @@ cloudflare_zone_id = "cloudflare-zone-id-here"
3971
github_repo = "Long104/Senzen"
4072

4173
# ─────────────────────────────────────────────────────────────
42-
# Public domains — defaults shown, override only if different
74+
# Environment customization (OPTION C — per-person environments)
75+
# Override these defaults to create your own isolated setup:
76+
# frontend_domain = "senzen-yourname.pantorn.site"
77+
# vercel_project_name = "senzen-yourname"
78+
# supabase_project_name = "senzen-yourname"
79+
# render_service_name = "senzen-api-yourname"
4380
# ─────────────────────────────────────────────────────────────
4481
# frontend_domain = "senzen.pantorn.site"
4582
# vercel_cname_target = "cname.vercel-dns.com"

0 commit comments

Comments
 (0)