Interview Prep/Terraform/HCP Terraform, OpenTofu, Scale and Cost

How do you keep module documentation up to date?

BeginnerProductionHCP Terraform, OpenTofu, Scale and Cost
Answer

Run terraform-docs in a pre-commit hook and CI check so the README's inputs, outputs and requirements tables are always generated from code.

terraform-docs markdown table --output-file README.md --output-mode inject .
All Terraform questions

More on HCP Terraform, OpenTofu, Scale and Cost