What is CI/CD? Why Do We Need CI/CD?

January 29, 2024

☕️ Support Us
Your support will help us to continue to provide quality content.👉 Buy Me a Coffee

CI/CD combines CI (Continuous Integration) and CD (Continuous Delivery/Deployment). While some companies have dedicated DevOps engineers handling CI/CD, many still rely on development engineers - frontend, backend, and full-stack developers - to manage these processes.

Over the next three articles, we'll explore the CI/CD fundamentals every engineer needs to know. In this first piece, we'll tackle the "why" behind CI/CD. When you understand the reasoning behind a technology, it becomes much more meaningful.

image
Source: https://www.linkedin.com/pulse/what-cicd-how-does-work-bestarion/

Why Do We Need CI/CD?

From a historical perspective, CI/CD is relatively new in software development. But why did it emerge? The answer lies in how we build software today.

Remember when software came on physical discs? Updates were major releases that happened months or years apart. Developers would complete entire feature sets, test everything thoroughly, then ship it all at once.

But something changed. In 2001, 17 senior software experts gathered to publish the Agile Manifesto. This sparked agile development practices, and CI/CD emerged as a natural evolution of these ideas.

But what exactly did the Agile Manifesto propose that made CI/CD necessary?

The Twelve Principles of Agile

  1. Our highest priority is to satisfy the customer through early and continuous delivery of valuable software.
  2. Welcome changing requirements, even late in development. Agile processes harness change for the customer's competitive advantage.
  3. Deliver working software frequently, from a couple of weeks to a couple of months, with a preference to the shorter timescale.
  4. Business people and developers must work together daily throughout the project.
  5. Build projects around motivated individuals. Give them the environment and support they need, and trust them to get the job done.
  6. The most efficient and effective method of conveying information to and within a development team is face-to-face conversation.
  7. Working software is the primary measure of progress.
  8. Agile processes promote sustainable development. The sponsors, developers, and users should be able to maintain a constant pace indefinitely.
  9. Continuous attention to technical excellence and good design enhances agility.
  10. Simplicity--the art of maximizing the amount of work not done--is essential.
  11. The best architectures, requirements, and designs emerge from self-organizing teams.
  12. At regular intervals, the team reflects on how to become more effective, then tunes and adjusts its behavior accordingly.

Notice the emphasis on "early delivery," "frequent delivery," and "continuous delivery"? This was a fundamental shift from the old model. Instead of shipping complete packages after months of work, teams needed to deliver value quickly and respond to feedback continuously.

But how do you actually make this work? How do you deliver software frequently without breaking everything? This is where CI/CD comes in.

What is CI/CD?

Let's break down CI/CD into its components:

CI (Continuous Integration) means multiple developers can work on different features in the same codebase and continuously merge their changes into a shared branch. Why do this continuously? Because the longer you wait to integrate changes, the more conflicts you'll face. Think of it like merging lanes in traffic - it's easier when done gradually rather than all at once.

During CI, automated tests and builds run to catch problems early. Imagine waiting until the night before launch to discover your code doesn't compile or fails tests. That's the nightmare CI prevents.

CD (Continuous Delivery/Deployment) automates the deployment process after integration. In the ideal scenario, when a developer merges code, it automatically integrates, tests, and deploys without human intervention. Your new feature reaches users seamlessly.

So CI/CD emerged as a practical solution to enable agile development. It automates code integration and deployment, freeing developers to focus on what they do best: building features.

You don't know what a complete CI/CD process actually looks like in practice. We'll dive deeper into that in the next article.

Now, you might wonder how CI/CD relates to DevOps? DevOps emerged around 2008-2009, while CI/CD concepts existed earlier but gained widespread adoption later. Today, CI/CD is a core element of DevOps. As Atlassian explains, building CI/CD pipelines is a crucial DevOps engineering skill, though DevOps encompasses many other capabilities as well.


Support ExplainThis

If you found this content helpful, please consider supporting our work with a one-time donation of whatever amount feels right to you through this Buy Me a Coffee page, or share the article with your friends to help us reach more readers.

Creating in-depth technical content takes significant time. Your support helps us continue producing high-quality educational content accessible to everyone.

☕️ Support Us
Your support will help us to continue to provide quality content.👉 Buy Me a Coffee