Why Pipeline replaced freestyle jobs

Jenkins CI/CD Course · lesson 3 of 15 · 5 min read

Moving the build definition into the repository is what made Jenkins jobs reviewable, branchable and disposable.

Open this lesson in the learning hub

Key points

  • A freestyle job lives as XML inside JENKINS_HOME, so the build definition is invisible to the repo.
  • A Pipeline job reads a Jenkinsfile from the checkout, so the build changes in the same commit as the code.
  • Freestyle has one flat list of build steps and no stages, so a long build reports as one opaque block.
  • A freestyle build dies when the controller restarts; a Pipeline build checkpoints and resumes after the restart.
  • A Multibranch Pipeline scans the repository and creates one job per branch and per pull request by itself.
  • Delete the branch and its job disappears, which is why nobody maintains a job list by hand any more.

Pipeline as code means the build lives in the repo, gets reviewed like code and dies with its branch.

This is a reading copy. The full lesson — with the visual explainer, the interactive lab and a Run button for the code — lives in the Jenkins CI/CD Course course, and every lesson in it is listed on the Jenkins CI/CD Course contents page.