terraform
terraform
Scope
Covers the Terraform language and workflow, and OpenTofu as a first-class peer: HCL style
and expressions, variable/output/local design, modules and their interfaces, count versus
for_each and the resource identity that follows from the choice, state (backends, locking,
splitting, sensitive values, migration), refactoring with moved/import/removed,
provider and runtime version constraints, terraform test, policy-as-code and configuration
scanning, environment layering, the concrete feature gaps between the two runtimes, and an
entry point to writing a provider.
The body is written against Terraform 1.16 and OpenTofu 1.12 (the current stable
releases). Every rule that needs a newer runtime than 1.6 carries a gate such as
(Terraform 1.11+); where the two runtimes differ the gate names both, because they have
diverged and a single number is now a wrong answer.
Not covered: