Bookmarks

CI/CD — continuous integration and continuous delivery

Continuous Integration, Continuous Delivery

A practice in which every code change is built and verified by tests automatically and reaches release through one and the same pipeline.

Also: CI/CD pipeline, continuous integration, continuous delivery, CI/CD

checked 9 Nov

All terms

Behind the abbreviation stand two practices. Continuous integration: developers merge their changes into a shared repository several times a day, and every change is built and verified by tests automatically. Continuous delivery: code that has passed the checks is always ready to go to production.

How the pipeline is structured

The pipeline is described in code and lives in the repository alongside the application: Jenkinsfile, .github/workflows/*.yml, .gitlab-ci.yml. On every change — a push or a pull request — the pipeline runs the same stages.

  1. Build and static analysis;
  2. Automated tests: unit tests first, then integration tests;
  3. Building an artefact, such as a container image, and publishing it to an artefact repository;
  4. Deploying to a staging environment and running acceptance checks;
  5. Release to production — automatic or at the press of a button.
yamlA minimal GitHub Actions workflow: build and tests on every push
            name: tests            on: [push]            jobs:              test:                runs-on: ubuntu-latest                steps:                  - uses: actions/checkout@v4                  - run: npm ci                  - run: npm test            

Delivery or deployment

StageWhat is automated
Continuous integrationbuild and tests on every change; deployment is never reached
Continuous deliveryeverything up to the final release: releasing to production is a deliberate human decision
Continuous deploymentthe release too: every change that has passed the checks reaches production by itself

Choosing between delivery and deployment is not about the tool but about the process. Martin Fowler puts it this way: with continuous delivery a release is possible at any moment, but the decision to release stays with a person — usually because the business prefers less frequent releases; with continuous deployment every change that has passed the checks goes to production. To release that often and without pain, teams use staged rollouts: canary releases, blue-green deployment and feature flags.

Where the term comes from

Continuous integration as an extreme programming practice was described by Martin Fowler and Matt Foemmel in a 2000 article. The term “continuous delivery” was established by Jez Humble and David Farley’s book “Continuous Delivery” of 2010. The effect of the practices is measured by the DORA metrics — from deployment frequency to the time it takes to recover from a failed deployment.

Sources

the term is written from these pages

Verified 9 Nov

Not to be confused with

what it is mixed up with and how it differs

  • DevOps

    DevOps is a culture of collaboration between development and operations; CI/CD is the pipeline through which such work is put into practice.

  • GitOps

    GitOps moves the desired state of the infrastructure into Git as well: the cluster pulls it from the repository itself and applies it.

In depth in the references

where the topic is covered in detail

Appears in the references