Sign in
Log inSign up

Jenkins-as-Code

Karl Fischer's photo
Karl Fischer
·Apr 2, 2019

Bootstrapping Jenkins in an automated way can be tedious. Ideally, you have a pre-baked image with plugins and baked in pipeline for configuration/seeding from a central git repository. From that point on a Jenkins config change is just a push to a git repository. The following approach leverages JobDSL, Groovy system scripts and JCasC to bootstrap Jenkins in a fully automated way.

Demo

Pictures can sometimes describe more than words ..

jenkins-bootstrap.gif

Repo

.. and code can describe even more! The demo was done with the following repository:

https://github.com/devtail/jenkins-as-code/

The code also contains agent-on-demand bootstrapping with Terraform.