practice

Infrastructure as Code

also called IaC

Defining infrastructure in version-controlled declarative files that a tool reconciles against the real environment.

terraformautomationreproducibility

The benefit is not automation for its own sake, it is that infrastructure gains the properties code already has: review, history, the ability to diff two environments, and the ability to recreate one from scratch.

Two significant caveats. State drift — someone changes something in the console and the code no longer describes reality — is the normal failure, and the answer is to remove console write access rather than to detect drift after the fact. And the state file itself becomes critical infrastructure: it holds secrets, it can be corrupted, and concurrent applies without locking will corrupt it.

The maturity marker is not whether infrastructure is in code. It is whether a production environment can be rebuilt from an empty account using only what is in the repository.