This project builds GEMs into Debian packages for multiple versions of Ruby and deploys them into the appropriate repositories.
The packages created are suffixed with the rubyversion being built to assist in identifying dependencies.
For example
rubygem-fluentd_0.12.8-9~ruby1.9.3-p194_all.deb
Each version of ruby must be configured in a config-VERSION.properties
file which describes
- The exact ruby version to use (eg 1.9.3 can be 1.9.3-p551)
- The location the gem's will be installed into, eg /var/lib/gems/1.9.1
- The Apt Repositories that the generated debian files will be deployed to (An array)
This configuration file, found here describes a ruby build environment for pre-jessie servers, where we install into the 1.9.1 directory, but actually compile for a 1.9.3 ruby version.
RB_VER=1.9.3-p194 RB_PREFIX=/var/lib/gems/1.9.1
REPOS=(jenkins@example.com:wheezy
jenkins-ci@example.com:squeeze
jenkins-ci@example.com:lenny)
The Jenkins job that builds this uses a Matrix Job configuration, so we can simultaniously build mutiple gems against different dependencies automatically.
The configuration can be summarised as:
- A build parameter named 'PACKAGE' which is the package the user wishes to package up
- A VERSION axis containing a list of versions which correspond to the CONFIG files included in this repo
- a single shell execution of
./package.sh $VERSION