Designed-in audit readiness: why compliance belongs in your IaC, not your wiki
Most SOC 2 programs fail at the same point — they treat compliance as a parallel system, not a property of the platform. Here's how to invert that.
- compliance
- platform-engineering
- soc2
Most fast-growing engineering teams discover compliance the same way: an enterprise deal stalls, the buyer asks for a SOC 2 report, and suddenly there’s a frantic six-month project that pulls senior engineers off the roadmap to write controls into a wiki. The result is a binder full of paragraphs that describe how the platform should work — paragraphs that begin drifting from reality the moment they’re signed.
That gap between what the wiki says and what production does is the entire failure mode. It’s the reason audits balloon. It’s the reason “passing SOC 2” feels like a victory you have to re-win every twelve months.
The shift: compliance as a property of the platform
The teams we work with don’t have a compliance program parallel to their engineering work. They have a platform whose defaults satisfy the controls. The control framework isn’t a binder — it’s a directory of policy files in the same repo as their Terraform.
When that’s true, three things change:
- Evidence is a build artifact. Every deploy produces signed attestations, structured logs, and policy-evaluation results. You don’t gather evidence at audit time; you export it.
- Drift is a build failure. A misconfigured S3 bucket isn’t a finding three months later. It’s a red CI check on the PR that introduced it.
- New controls ship like features. Need to add a new ISO requirement? It’s a PR to the policy directory, reviewed and merged like any other code change.
What “designed-in” actually means in code
Concretely, this looks like:
- OPA / Conftest running in CI against every Terraform plan. Wildcard IAM policies fail the build. Unencrypted resources fail the build. Public ingress without explicit approval fails the build.
- Kyverno running in every cluster, blocking workloads that don’t carry an identity, don’t have resource limits, or don’t run in the right namespace.
- Cosign + SLSA attestations on every container image, with the cluster admission controller rejecting anything unsigned.
- A single control-mapping file that points each SOC 2 control to the specific policy file or pipeline step that enforces it. When an auditor asks, “how do you enforce CC6.1?”, the answer is
policies/cc6/least-privilege.regoand a link to the CI run that proves it.
The auditor doesn’t need a tour. They need a git log.
Why this matters more for early-stage teams
If you’re 250 engineers deep into a 10-year-old codebase, retrofitting this is hard. If you’re 30 engineers and your platform is younger than your Series A, this is the cheapest it will ever be. Every quarter you delay, the cost grows roughly linearly with your headcount and exponentially with the breadth of your services.
The right time to design-in audit readiness is before the deal that requires it. The second-best time is the sprint you scope after the deal slips because the buyer’s security questionnaire timed out.
The shape of an engagement
When we run this work, the first two sprints are almost always the same:
- Sprint 1: control-mapping audit. We translate the framework you need (SOC 2 Type II, ISO 27001, or both) into a structured map of which controls are evidenced where today, and which aren’t evidenced at all.
- Sprint 2: pipeline-enforced controls for the most critical gaps. Usually IAM scope, network policy, and signed builds — the three places where “we’ll fix that later” becomes “we failed the audit.”
By the end of Sprint 2, the platform itself enforces what the policy says. From there, every subsequent sprint is incremental — more controls, more automation, less wiki.
That’s the model. Code, not spreadsheets. Defaults, not paragraphs. Audits that take days, not quarters.
Want this in your stack?