Flowchart examples · Engineering

CI/CD pipeline flowchart

Pull request to production, with the gates that stop a bad change and the rollback path when one gets through.

CI/CD pipeline flowchart

CI/CD pipeline flowchartNoYesNoYesYesNoYesNoDeveloper opens pullrequestBuild and run unit testsLint and security scanChecks pass?Developer fixes andpushesCode reviewApproved?Merge to mainDeploy to stagingSmoke tests pass?Deploy to productionHealth checks OK?Automatic rollback andalertRelease done

A worked example to adapt. Rename steps, add branches and owners to match how your team actually works.

Edit the steps to match your process. The free preview (no sign-up) drafts up to 8 main steps; add branches and the remaining steps in the editor.
Mermaid source for this diagram
flowchart TD
  s(["Developer opens pull request"])
  build["Build and run unit tests"]
  scan["Lint and security scan"]
  d1{"Checks pass?"}
  fix["Developer fixes and pushes"]
  rev["Code review"]
  d2{"Approved?"}
  merge["Merge to main"]
  stg["Deploy to staging"]
  d3{"Smoke tests pass?"}
  prod["Deploy to production"]
  d4{"Health checks OK?"}
  rb["Automatic rollback and alert"]
  e(["Release done"])
  s --> build
  build --> scan
  scan --> d1
  d1 -->|No| fix
  fix --> build
  d1 -->|Yes| rev
  rev --> d2
  d2 -->|No| fix
  d2 -->|Yes| merge
  merge --> stg
  stg --> d3
  d3 -->|Yes| prod
  d3 -->|No| fix
  prod --> d4
  d4 -->|Yes| e
  d4 -->|No| rb

Paste into any Markdown tool that renders Mermaid, such as GitHub.

About this ci/cd pipeline flowchart

A CI/CD diagram is useful when it shows the gates, not just the stages. Each diamond in this example is a point where the pipeline can stop a bad change: failing checks, a rejected review, failed smoke tests or unhealthy production metrics.

It fits a trunk-based team deploying a web service with GitHub Actions, GitLab CI or similar.

Step by step

  1. Continuous integration. Every push builds, runs unit tests, lints and scans dependencies.
  2. Review. A teammate reviews; requested changes loop back to the developer.
  3. Staging. Merged code deploys to staging and runs smoke tests.
  4. Production. Passing builds deploy to production.
  5. Rollback. If health checks fail after release, roll back automatically and alert the team.

How to make it in flow-chart.io

  1. Start from the example. Edit the text in the generator box above so it names your own CI tool, environments and checks, then press Generate. The free preview needs no sign-up.
  2. Add the branches. Add the decision points that matter for you, for example manual approval for production? or canary release. Each decision becomes a diamond with labeled outcomes.
  3. Assign owners. Save the diagram to the editor (free account) and rename steps to show who does what: developer, reviewer and the pipeline.
  4. Share or export. Share a read-only view link: people with the link can view the diagram but not edit it. Downloads as PNG, SVG or PDF are part of Flow Pro (see pricing).

Tips

Frequently asked questions

What is the difference between CI and CD?
Continuous integration builds and tests every change; continuous delivery or deployment automates releasing changes that pass.
Should I include canary or blue-green deploys?
Yes, if you use them. Add a canary step and a decision on its metrics before full rollout.
Is there a DevOps pipeline guide?
Yes; see the DevOps pipeline diagram guide linked below.

Related

Code review process flowchartIT change management process flowchartIncident response process flowchartDevOps pipeline diagramsGit flow diagramsAll flowchart examples

Build it from your own words

Describe your process and get an editable diagram. Free to build and edit; Flow Pro adds downloads and unlimited projects.

Start free See pricing