Skip to content
All use cases

Reference scenario · Platform engineering & DevOps

A Terraform delivery path with reviewable blast radius

Boundaries that follow ownership and change cadence, plans a senior engineer can read, and an apply identity that can only touch one state.

Example stack
Terraform · OIDC
Scope
State, modules, environments
Output
Reviewable plan and per-state apply

A composite reference scenario built from the four offers. It is not a named client engagement; no client names, metrics or outcomes are implied.

01 · The problem

  1. Terraform makes it easy to put a resource in a file and apply it. The harder question is what belongs together. Every boundary decides who can change what, how large a plan is, and how far a mistake travels.
  2. The usual symptoms are recognisable. One state means every plan can touch anything and one lock stops all teams. A folder per environment drifts until staging and production differ in ways nobody documented. Policy checks run after merge, so the review happens when the change is already inevitable.
  3. None of that is a tooling problem. It is a boundary problem, and it shows up as plans that reviewers approve by pattern rather than by consequence.

02 · The architecture

Teams whose infrastructure repository has outgrown its layout: one large state, copy-per-environment folders, or plans nobody can review. The diagram is the shape of the answer; the text version below it is the same argument in reading order.

Fig. 01 — The pull request produces one plan for one state; approval names that state, and the apply identity can reach nothing else.
Text version of this figure
  1. A module interface and one environment's inputs compose into a single plan.
  2. Policy, cost, and contract checks evaluate that plan inside the pull request, before merge.
  3. A reviewer approves consequences for a named state, and production needs an explicit approval.
  4. Apply assumes a per-state role through OIDC and writes to one state backend only.
  5. Scheduled drift detection compares reality to the same state and feeds the next plan.

03 · How the work runs

  1. Map the current blast radiusList every state, its owner, its apply cadence, and the largest plausible change one apply could make. Ask who is paged when it fails. That inventory usually identifies two boundaries that carry most of the risk.
  2. Redraw modules as decisionsReplace folder-shaped modules with interfaces for decisions the platform team makes repeatedly: a subscription vending unit, a standard workload network, a cluster baseline, a logging destination. Keep the input surface small and opinionated.
  3. Compose environments instead of copying themUse small root modules that call shared modules, with environment differences in version-controlled inputs. Differences should be visible in one place and limited to scale, retention, ranges, identity, and feature flags.
  4. Make the plan the proposalRun policy, cost, and contract checks inside the pull request. Split mechanical refactors from behaviour changes so the diff shows intent, and require a reviewer to state the consequences in one sentence.
  5. Separate plan from applyPlan runs with a read-only identity. Apply runs with a per-state role obtained through OIDC, behind an approval that names the state. Drift detection compares reality to the same state on a schedule.

04 · The controls

  1. Each state has one owning team and one apply identity; no shared long-lived cloud credentials in CI.
  2. Plan identity is read-only. Apply identity is scoped per state and only assumed after approval.
  3. Secrets stay out of state and plan output; sensitive values come from a secret store at runtime.
  4. Environment differences are declared, reviewed, and limited; a security control that differs between environments needs an explicit decision record.
  5. Production apply requires a named approver and a rollback note, not a second click on the same button.

05 · Trade-offs

What each decision buys — and what it asks the client to give up.
DecisionWhat you gainWhat you give up
Split state along ownership boundariesCross-boundary references become explicit outputs and data sources instead of a shared backend read.More states means more coordination and more wiring between them.
Migrate one large state into severalImports and moved blocks reduce the risk of the split.It is still a real migration: imports and moved blocks do not remove the need for a quiet window and a verified plan.
Run policy and cost checks in the pull requestThey pay back when they catch a replacement nobody intended.They add minutes to delivery and they need maintenance.
Teams own their module reviewsReview capacity sits with the people who know the workload.A platform team that reviews everything becomes the bottleneck the boundaries were meant to remove, and the design assumes review capacity that not every team has yet.

06 · What changes

  • A plan for one state is short enough that a reviewer can explain its consequences without opening module source.
  • The largest plausible blast radius of one apply is written down and accepted by the owning team.
  • Drift is detected on a schedule rather than discovered during an incident.
  • A provider or module upgrade has a visible lane in the backlog instead of arriving as a surprise.

07 · Out of scope

  • Not a tool migration: existing pipelines and clusters are assessed before anything is rewritten.
  • Design and review can be delivered without taking over day-two operations.
  • Cluster and pipeline changes follow the client's change process and windows.
  • Kubernetes is treated as an operating model, not a default target for every workload.

Talk through your context.

Bring the constraint you are working around. A first conversation is about naming it, not pitching a programme.