Introduction to CI/CD and its tools

Guneet Singh
4 min readJun 29, 2022
Toolbox of DevOps

At some point in our development lifecycle, we all get fed up doing the same tasks every time before making new releases. And that is the same time we wish to bring automation to work.

Although automation is a big topic depending upon the processes you want to automate (e.g. account creations, allocating resources, granting access, testing, etc.) it is among the basic tasks of DevOps and takes more advanced tools (check Ansible for example), CI/CD is the most common among developers to utilize.

CI/CD as we know stands for Continuous Integration and Continuous Deployment which includes but is not limited to the following tasks:

  1. Testing and compiling code
  2. Generating builds
  3. Signing builds
  4. Releasing, publishing or distributing builds
  5. Monitoring

There are 3 common terms that are used while working with CI/CD:

  1. Pipeline: A pipeline is a sequence of steps that needs to pass where the output of one step can be used as an input of another step to complete the desired task.
  2. Steps: Each step in a pipeline involves some computation job which will result in succession or halt of the current step.
  3. Jobs: Each step may involve one or more than one job which can run parallelly.

This can also be understood with the below image:

Example CICD pipeline

There is a wide range of tools doing the same work as CI/CD with its own pros and cons. The main parameters of concern are cost, developer experience, and community support. The most famous ones are:

  1. Jenkins
  2. GitLab
  3. Bamboo by Atlassian
  4. TeamCity by Jetbrains
  5. TravisCI
  6. CircleCI
  7. Buildkite
  8. Drone

Let’s dig into the pros and cons of some of them:

GitLab

So far the fastest-growing CI/CD tool is GitLab due to its own ecosystem of tools starting from VCS, issue tracking, CICD (obviously) and a range of external app integration (e.g. Jira, YouTracker, Slack to name a few).

Jenkins

Another tool i.e. Jenkins is pretty much the only open-source CI/CD platform availabale that has good support when it comes to the third-party service integrations e.g. you can integrate GitLab to use Jenkins to handle CI/CD. Jenkins is also doing great to enhance its developer experience with the BlueOcean plugin which makes it easier to visualise and create CI/CD pipelines through UI.

TeamCity

But if you are not a big follower of open source products then TeamCity (by Jetbrains) might be a great fit for you due to its ease of setup, wider support and UI-driven pipeline creation. Also, it is completely free with up to 100 build configurations for your “on-premise” TeamCity setup.

Wait, what’s this “on-premise” mean…

This is very much like a local VCS (or git basically) where all the resources being used are the underlying device. There is a remote variant of the so-called on-premise setup of CI/CD that runs on the cloud infrastructure that you configure (e.g. storage, bandwidth, CPU, RAM, etc.)

All the CI/CD platforms provide their own cloud counterparts of their on-premise application and vice-versa. If one doesn't provide its own support to run the CI/CD pipelines over the cloud then you can always use Docker (or a similar container) to allocate the resources on the go and execute the pipeline.

CI/CD on cloud environments mostly incurs some cost and is mainly useful if your pipeline takes large enough time(e.g. > 1 hour) on a local device that can compensate for the extra cost of executing it on a remote or virtual device where the same can execute in a few minutes.

This was all for an introduction to CICD. As one can see in this above image, there is a lot more that can be added to a CICD pipeline as per the process requirement (e.g. integration with DataDog to monitor logs, Jira for issue tracking, deployment API integration, etc.), it is out of the scope of this blog. In the next blog, I will be sharing how you can set up Jenkins locally to bootstrap CICD in your project.

--

--