How to create a build farm.

Installation/Preparation

Install the necessary base packages

 sudo aptitude install pbuilder cowdancer reprepro rebuildd

  • pbuilder: package to build Debian packages
  • cowdancer: speed up pbuilder builds
  • reprepro: Create repository from built packages
  • rebuildd: manager for rebuilding packages

Install the latest debootstrap available. That means for building packages for Debian only, just take the latest one from sid, if you want to build both Debian and Ubuntu packages take the latest one from Ubuntu, since this extends the Debian one. Usually, this can be installed simply by e.g.
 sudo dpkg -i debootstrap_1.0.3build1_all.deb

Try to find it here for Ubuntu [13]

Configure first build environment

Create a build user
 sudo adduser dbuild
and log in as this user.

Make some directories:
 cd $HOME; mkdir cow config result-deb build

Create a config file as described later under 1. Configuration files and create the build environment
 fakeroot cowbuilder --create --configfile=config/cowbuilder-amd64-gutsy

Configuration files

These are pretty minimal configuration files:

Finally, here is the sid config file with annotation:

 # which distribution?
 DISTRIBUTION=sid
 # where to place the final .deb packages
 BUILDRESULT=$HOME/result-deb/$DISTRIBUTION
 # where to build the packages
 BUILDPLACE=$HOME/build/$DISTRIBUTION
 # base path of cow (copy on write) master directory
 BASEPATH=$HOME/cow/$DISTRIBUTION
 # which mirror to use for downloading stuff
 MIRRORSITE=http://ftp.de.debian.org/debian/
 # which components are included?
 COMPONENTS="main non-free contrib"
 # correct the UID of final packages to
 BUILDRESULTUID=1004
 # where to store the already retrieved packages
 APTCACHE=$HOME/aptcache/$DISTRIBUTION
 APTCACHEHARDLINK=yes

DocumentationForm edit

Title How to create a build farm
Description This pages explains how to create a build farm.
Tags build farm
Category Admin, Developer
Topic revision: r4 - 10 Feb 2012, ArthurVarkentin
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki? Send feedback