The upstream attic-iac CI/CD pipeline is structured around five sequential stages that take changes from validation through to production deployment.
Static checks that run before any build or deploy work begins.
organization.yaml and checks
schema conformance, required fields, and cross-references between runners,
environments, and cache settings..tf files follow canonical formatting.tofu validate against every module in
tofu/modules/ to catch syntax errors, missing variables, and provider
misconfigurations.Produces the artifacts needed by later stages.
pnpm install && pnpm build for the
SvelteKit runner-dashboard application using adapter-node.Generates OpenTofu execution plans for each infrastructure stack.
Each plan is saved as an artifact and passed to the deploy stage.
Applies the saved plans from the previous stage.
tofu apply using the exact plan artifact produced in the Plan stage.Post-deployment health checks confirm services are running.
A scheduled pipeline runs independently of code changes. It executes
tofu plan -detailed-exitcode against each stack. A non-zero exit code
indicates configuration drift (manual changes made outside of tofu), which
triggers an alert.
graph LR
V[Validate] --> B[Build]
B --> P[Plan]
P --> D[Deploy]
D --> VR[Verify]
S[Schedule] -->|"drift detection"| VR