Interview Prep/DevSecOps/Supply Chain Security

Why should you "build once, promote the same artifact" across environments?

IntermediateScenarioSupply Chain Security
Answer

Situation read → Rebuilding per environment means production runs something that was never tested or scanned.

What I'd do →

  1. Build and push one image tagged with commit SHA, record the digest.
  2. Scan, sign and attest it once.
  3. Promote by deploying the same digest through dev, staging and prod via GitOps PRs.
  4. Keep environment differences in config, not in builds.
  5. Admission policy checks the signature in every environment.

Why → What you tested and signed is exactly what runs in production.

Interview tip → Rebuilding for prod breaks the chain of evidence.

All DevSecOps questions Roadmap: Supply chain, secrets & identity

More on Supply Chain Security