modified version of jenkins debian glue ( for devuan
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Michael Prokop 9cc04d9b2b move all scripts to scripts/ directory 10 years ago
debian Make Debian package a native one. 11 years ago
examples support multi arch builds for mixed architecture all and any binary builds 10 years ago
git git hook: adjust file name information in header. 11 years ago
scripts move all scripts to scripts/ directory 10 years ago
tests move all scripts to scripts/ directory 10 years ago
LICENSE License jenkins-debian-glue under MIT terms. 11 years ago
Makefile move all scripts to scripts/ directory 10 years ago
NOTES Add NOTES file (with hints regarding jenkins.rb). 11 years ago Support /etc/jenkins/debian_glue for setting key id for reprepro. 11 years ago


This Debian package provides scripts for building Debian packages inside Jenkins (being a Continuous integration system). Currently being a test driven and user needs driven prototype it's meant to make Q/A builds of Debian packages inside Jenkins as manageable and homogeneous as possible.

System requirements

  • Jenkins

  • Cowbuilder

  • Reprepro

Setup instructions

Jenkins jobs for a given Debian package foobar needs to be named foobar-binaries and foobar-source. foobar-source is the job name where the source package is being built and foobar-binaries is the job name where the Debian binary packages are being built.

If a second job for an already existing job for the Debian package foobar should be available then the name foobar-test with the according Jenkins jobs foobar-test-source and foobar-test-binaries is supported.

Source job configuration (foobar-source)

Choose "This build is parameterized" to be able to build specific branches.

Enable and configure "Source Code Management", currently only Git is supported by the generate-git-snapshot script. (NOTE: Scripts for other version control systems are highly welcome!) Important: set the "Local subdirectory for repo (optional)" option under Advanced settings to "source".

Enable "Trigger builds remotely" and set an user-defined authentication token.

Use @daily inside "Poll SCM".

In the "Build" section add a build step "Execute shell" using:

/usr/bin/generate-git-snapshot auto

Under "Post-build Actions" select "Archive the artifacts" using:


Select the binaries job (foobar-binaries) under "Build other projects" with the "Trigger only if build succeeds" option enabled.

For "Files to deploy" enable "Deploy artifacts from workspace to remote directories" using:


and for the "Remote directory" use:


Enable "Record fingerprints of files to track usage" and "Fingerprint all archived artifacts".

Binaries job configuration (foobar-binaries)

Add a "Configuration Matrix" with user-defined Axis titled "architecture" and values "amd64 i386", specifying the architectures that should be built. Choose "Run each configuration sequentially".

In the "Build" section add a build step "Execute shell" using:


Under "Post-build Actions" select "Archive the artifacts" using:



  • build-and-provide-package: searches for newest package version in ${HUDSON_HOME}/userContent/${PACKAGE}-source/ and uses the dsc file for building a binary package for the specific $architecture of the matrix build using cowbuilder. The resulting binary package will be installed in reprepro to provide it for usage via APT. i386 builds are binary-only builds (limited to architecture dependent packages) and amd64 builds are binary-only builds (no source files are to be built). With the amd64 build the original dsc file is being installed in reprepro as source package.

  • generate-git-snapshot: generates a snapshot version of a Debian package using git-dch. Use 'auto' as command line option to use git-dch's magic to build changelog, without the 'auto' option the version string will be build based on last tag/merge.

  • generate-local-repository: scans the current working directory for Debian packages and generates Packages.gz, Contents and Release files. Meant for usage if reprepro would be overkill (e.g. no signed repository is needed).

  • generate-reprepro-codename: takes a repository/codename as command line option and adds an according repository/codename definition to /srv/repository/conf/distributions (iff the codename is not present yet). As second command line option the GnuPG key ID for signing the repository can be specified (defaults to a static value otherwise).

  • generate-svn-snapshot: generates snapshot version of a Debian package using svn log, svn2cl and some dirty shell magic.

  • increase-version-number: takes a version number as commandline argument and raises the version number for usage inside as a new snapshot version. It does not append any special characters (like $BUILD_NUMBER or VCS revisions), so you can use it with your own suffix, build numbers, VCS info, etc.

Known TODOs

  • Make configuration more flexible (repository path, cowbuilder base dirs,…).

  • Separate cowbuilder and reprepro steps in build-and-provide-package (e.g. to use generate-local-repository instead of reprepro).

  • Make sure scaling with slave node works (including tagging of hosts, deploying files,…).

  • Provide Jenkins plugin to deploy and configure cowbuilder.

  • Provide Jenkins plugin to deploy and configure reprepro (including gpg key).


Michael Prokop <>