Interview Prep/CI/CD/Pipeline Design and Architecture

What does a good production CI/CD pipeline look like end to end?

BeginnerProductionPipeline Design and Architecture
Answer

In production we aim for one pipeline per service with these properties: triggered by PR and merge, runs in under 10 minutes for PR feedback, builds one immutable artifact, scans it, deploys to staging automatically, runs smoke and integration tests, then promotes the same artifact to production with a gate (automated or approval). Every step is code, every environment is created from code, and every deployment is traceable to a commit.

flowchart LR
  A["PR opened"] --> B["Lint + unit tests"]
  B --> C["Build image + scan"]
  C --> D["Merge to main"]
  D --> E["Deploy staging"]
  E --> F["Integration + smoke"]
  F --> G["Approval or auto gate"]
  G --> H["Deploy production"]
  H --> I["Verify + auto rollback"]
All CI/CD questions Roadmap: CI/CD fundamentals

More on Pipeline Design and Architecture