After a year of growth, the team has 60 stacks with inconsistent practices. How do you standardise without stopping delivery?
AdvancedScenarioTesting Upgrades and Large-Scale Operations
Answer
Situation read → Organic sprawl.
What I'd do →
- Inventory stacks: Terraform versions, provider versions, backend types, owners.
- Publish a baseline template repo (backend, pre-commit, CI, policy) and a migration guide.
- Migrate by risk and value: top 10 critical stacks first, with no-diff plans.
- Track compliance in a scorecard; make new stacks use the template by default.
Why → Incremental, measured migration beats a freeze; the template makes the right way the easy way.
Interview tip → Show a metric, such as the percentage of stacks on the baseline.
More on Testing Upgrades and Large-Scale Operations
What does each of `terraform validate`, `plan` and `terraform test` actually check?BeginnerWrite a native test for a module that creates an encrypted S3 bucket.IntermediateCompare Terratest with `terraform test`.IntermediateReal-cloud integration tests leave orphaned resources when they fail midway. How do you handle that?AdvancedHow do you upgrade from Terraform 1.5 to 1.9 safely?IntermediateMajor AWS provider upgrade from v4 to v5 (or v5 to v6) across many stacks. How do you plan it?Advanced