A CI/CD pipeline is the automated route your code takes from your laptop to the people using it. Every change is built, checked and moved through the same series of environments in the same way, so a machine catches problems long before a user does.
What CI and CD mean
Continuous integration (CI) means everyone merges small changes into a shared branch often, and every change is built and tested automatically as soon as it arrives. The point is to find bugs and conflicts while a change is small and fresh in your head, rather than in a painful merge weeks later.
CD has two meanings that are easy to mix up:
- Continuous delivery: every change that passes the pipeline is ready to release, but a person decides when it goes to production.
- Continuous deployment: every change that passes goes to production automatically, with no human step.
Most teams start with continuous delivery. Continuous deployment needs a lot of trust in your tests and monitoring, because nothing stands between a merged change and your users.
The pipeline is what runs all of this: a list of stages, defined in a file in your repository, that runs every time code is pushed. GitHub Actions, GitLab CI/CD, Jenkins and Azure Pipelines are common tools for it, and the ideas are the same in all of them.
From local to the pipeline
Your laptop is your local environment. You write code, run it and perhaps run a few tests. But 'works on my machine' proves little: your machine has tools, files and settings nobody else has.
Pushing to the shared repository hands the code to the pipeline. It starts from a clean machine, usually a fresh container or virtual machine, fetches your code and builds it from scratch. That clean start is much of the value: if the build depends on something only your laptop has, the pipeline finds out straight away.
What 'build' means depends on the project:
Wondering how this was made? How we make these