CI/CD

Where do you store CI/CD pipelines? Why?

Difficulty: unrated

Source: bregman-arie/devops-exercises by Arie Bregman

Answer

There are multiple approaches as to where to store the CI/CD pipeline definitions:

  1. App Repository - store them in the same repository of the application they are building or testing (perhaps the most popular one)
  2. Central Repository - store all organization's/project's CI/CD pipelines in one separate repository (perhaps the best approach when multiple teams test the same set of projects and they end up having many pipelines)
  3. CI repo for every app repo - you separate CI related code from app code but you don't put everything in one place (perhaps the worst option due to the maintenance)
  4. The platform where the CI/CD pipelines are being executed (e.g. Kubernetes Cluster in case of Tekton/OpenShift Pipelines).