The Difference Between Continuous Integration, Deployment and Delivery
Tags: devops, programming, productivity
Published: 2020-12-17 11:25:42

Frequently used in modern development practices and DevOps, continuous integration (CI), continuous deployment (CD), and continuous delivery (CD) are like vectors that have the same direction, but different magnitude. 

![CI CD CD](https://dev-to-uploads.s3.amazonaws.com/i/qkbxgzk9lb9lvu05pr8a.png) 
 
Their goal is the same: make our software development and release process faster and more robust by speed delivery and accuracy, giving developers the tools they need to deliver better products, with fewer bugs, and implement improvements. continuously. 

So, what’s the difference between continuous integration vs continuous delivery vs continuous deployment ? How they are linked with each other and what are the benefits to opt them ….

#1) Continuous Integration (CI)
![Continuous  Integration](https://dev-to-uploads.s3.amazonaws.com/i/0m9ywqj63n2uf17d6rag.jpg)

Is about automating build and test processes to make sure the resulting software is in a good state, ideally every time a developer changes code.

So CI is the process of enforcing developers to merge their code to mainstream branch or working code base as often as possible.

CI Involves triggering a build when a change gets committed to the source code repository by any developer. which includes, fetching the code from source code repository, compiling code, running automated tests and creating build out of it. 

CI benefits developers most because it allows for code produced to be automatically tested and continuously “integrated” with other developers’ code, and with the existing codebase.

The developer benefits from receiving continuous and immediate feedback regarding code and integration errors. Fixing these errors, automated testing tools in this stage will report if the errors were successfully fixed and when the code is accepted. This continuous feedback loop dramatically increases a developer’s productivity.

#2) Continuous Delivery (CD)
![Continuous Delivery](https://dev-to-uploads.s3.amazonaws.com/i/44li2u4ck3me7c3d20ex.jpg)

Continuous delivery is an extension of continuous integration since it automatically deploys all code changes to a testing and/or production environment after the build stage. So **No Continuous Integration, No Deal**. 

This means that on top of automated testing, you have an automated release process and you can deploy your application any time by clicking a button.

The goal of Continuous Delivery is to make sure the software is always ready to be released but isn’t pushed to production unless you make the decision to do so. It is a manual step.


#3) Continuous Deployment (CD)
![Continuous Deployement](https://dev-to-uploads.s3.amazonaws.com/i/u7fcrzqrpvubic5uxlz8.jpg)

Continuous deployment goes one step further than continuous delivery.It's a process that automatically deploys the results of Continuous Delivery into the final production environment, usually every time a developer changes code (assuming all automated tests pass).

There's no human intervention, and only a failed test will prevent a new change to be deployed to production.

Continuous deployment is an excellent way to accelerate the feedback loop with your customers and take pressure off the team as there isn't a Release Day anymore. Developers can focus on building software, and they see their work go live minutes after they've finished working on it.

#4) Continuous integration VS Continuous Delivery VS Continuous Deployment

![Continuous-Integration-vs.-Continuous-Delivery-vs.-Continuous-Deployment](https://dev-to-uploads.s3.amazonaws.com/i/8f9qapc1zjjlxdhgrchb.jpg)
 
Continuous integration is the beginning of the cycle where builds are created and tested. 

Continuous delivery encompasses the cycle from the beginning of CI and ends with the “release” of the verified artifacts packages, VM or container images published onto a download server. 

Continuous deployment ensures that qualified releases are automatically deployed to production taken from the download servers and made the currently running version in one or more environments/locations, typically also using rolling upgrades in order to ensure that applications remain available to users during the process.

![ManualVSAutomatic](https://dev-to-uploads.s3.amazonaws.com/i/b4h6b1fmsheff7oertjx.jpg)
 
Continuous Delivery is when your code is always ready to be released but isn’t pushed to production unless you make the 
decision to do so. It is a manual step. With Continuous Deployment, any updated working version of the app is automatically pushed to production.

#5) Continuous Process Benefits :
![Benefits-of-CI_CD-6](https://dev-to-uploads.s3.amazonaws.com/i/4patiobucr7edmxamz7m.png)
 
- Continually integrate and test to reduce risk.
- Build Stuff Faster and never ship Broken Code Into Production.
- Easy detection of integration Bugs.
- Consistency of Build Process.
- Always have a deployable build.
- Generate metrics to guide project management.
- Increases Confidence in the Software.
- Accelerated Time to Market.
- Improved Productivity and Efficiency.
- Improved Customer Satisfaction.

#6) Continuous Process Tools 
![ContinuousDeliveryToolLandscape](https://dev-to-uploads.s3.amazonaws.com/i/im5veg3dcyyy00eaj20b.jpeg)

Development teams can take advantage of Continuous Integration by deploying a solution such as Jenkins, the most popular open source tool in the space, and configuring it to build and test their code. Also we can use Bamboo, TeamCity, Buddy...  

Continuous Delivery usually involves other DevOps-related tools like Puppet, Chef, Ansible, or SaltStack to install and configure environments for testing. Docker and container orchestration components like Kubernetes make it easier for teams to automatically set up and tear down these environments as part of the CI/CD process. The open source project Spinnaker, created by Netflix, provides a robust Continuous Delivery and Continuous Deployment solution. 
 
There exist several tools, depending on the requirement the tools can be selected.

#Conclusion
Like many technological concepts, continuous integration, continuous delivery, and continuous deployment are terms that DevOps teams use without defining them precisely. So, it’s worth taking a closer look at what each of these terms actually means.

I hope you now get the difference between Continuous Integration, Continuous Delivery and Continuous Deployment.

Altogether the practices create an efficient system free of bugs and ready for use.