advanced

Infrastructure as Code

Define cloud and platform infrastructure through versioned code, reviewable plans, state, and environment promotion practices.

IaC interviews compare declarative cloud management through reviewable plans, modules, state, and environment promotion—often with Terraform or TypeScript-friendly Pulumi for JavaScript teams.

Subtopics: Pulumi, Terraform, state management, environments.

On interviews: explain remote state locking, plan-before-apply in CI, separating dev and prod state, and drift from console edits.

Common pitfalls: local state in Git; shared state across environments; unreviewed applies; secrets in plain values files.

The trade-off is infrastructure agility versus governance, auditability, and blast-radius control.

Checklist:

  • Plan in CI; apply through gates.
  • Isolate state per environment.
  • Pin providers and modules.
  • Detect drift on a schedule.