CI/CDIntermediate4h

Jenkins & alternatives.

Self-hosted CI, pipelines as code, and when to use it.

What is Jenkins?

Jenkins is a self-hosted automation server that has run CI/CD for decades. You run it on your own infrastructure and define pipelines as code in a Jenkinsfile. It trades the convenience of hosted CI for total control and on-prem capability.

Why it matters

Many established companies run Jenkins, and plenty of regulated or air-gapped environments cannot use a hosted service. Recognizing the self-hosted CI model — its strengths and its operational burden — rounds out your CI knowledge beyond a single vendor. You may well inherit a Jenkins setup.

What to learn

  • The self-hosted CI model and its trade-offs
  • Pipelines as code with a Jenkinsfile
  • Agents and distributing builds
  • Plugins, and the maintenance they bring
  • Credentials management in Jenkins
  • When self-hosted CI is the right call
  • Comparable tools: GitLab CI, CircleCI, Drone

Common pitfall

Treating self-hosted CI as free because there is no per-minute bill. Someone has to patch, upgrade, secure, and babysit the server and its plugins — a real, ongoing cost. Choose self-hosted when control or compliance demands it, not to "save money," because the operational time is rarely free.

Resources

Primary (free):

Practice

Sketch a pipeline-as-code definition (a Jenkinsfile or GitLab CI file) for the same install-test-build flow you built in Actions. List what you would have to maintain to run it yourself. Done when you can argue when self-hosted CI is worth the operational overhead.

Outcomes

  • Explain the self-hosted CI model and its costs.
  • Define a pipeline as code in a Jenkinsfile.
  • Manage credentials and agents in a self-hosted system.
  • Decide when self-hosted CI beats a hosted service.
Back to DevOps roadmap