Was Java architect and developer for 7 years before that • Originally from Russia, but lived and work in US, UK, Denmark and now in Singapore • Follow me on Github: @lechat
Jobs of course, they only exist in Jenkins and handcrafted to perfection • Builds a history of (not so) useful information • Keys usually forgotten essential bit of information
Jobs Trivial approach - make shell script that will put files somewhere else Another trivial approach - use Jenkins job to save Jenkins as build artefact • Useful only as a disaster recovery Restoring just one job requires Jenkins restart (only in latest version there is an option to reload job definition)
keep job definition with your source code? Use jenkinsapi library to save/restore jobs! What jenkinsapi can do? • Query Jenkins about jobs, builds, views, nodes • Create/update jobs, views, nodes (only JNLP nodes for now) • Execute jobs
for jobs • Create variables and expand them when job is generated • Create default values used across multiple jobs • Define macros for repeated sections
Hudson job creator https://github.com/hudson2-plugins/jobcreator-tool Source code for this presentation https://github.com/lechat/devops-python-jenkins