From Fedora Project Wiki

Plague Target Configuration

Plague defines multiple targets, some are defined on the server, and some are defined on the builder(s). The server targets define a distribution including all target architectures, a cvs_root (if used), etc. The builder targets define a single build target, such as Fedora Core 4 on i386. Each type of target config file is explained below.

Target files must be named <something>.cfg to be recognized as config files.

Server Targets

Target configuration files are used on the build server to configure a number of things:

  • Which architectures a package needs to be built for given a target distribution
  • Define aliases used when requesting builds - ie. a user requests a build on '4', this could get expanded out to Fedora Core 4.
  • If a given distro is accessed via CVS, the cvs_root is defined here

Here is an example for a server target file

[General] 
distro = fedora
target = 4
repo = core
testing = yes
repo_script =

[Arches] 
base_arches = i386 x86_64 ppc
optional_arches = i686 noarch

[Aliases] 
cvs_alias =
user_aliases = fc4

[Additional Packages Arches] 
kernel = i686

[CVS] 
cvs_root =
cvs_rsh =

Server targets are all stored in a directory defined in your server config:

target_configs_dir = /etc/plague/targets

You need one target config for each distribution you want to build for.

Builder Targets

Builder target configurations are a lot shorter than the server targets. For each distribution, you will need to have a builder target config for each architecture in that distribution. The builder target configs simply tell the builder which mock configuration to use for which target OS/Arch. For example, if you want to build FC4 x86_64 and i386 packages on a machine, you will need to have two separate builder target files. First:

[General] 
distro = fedora
target = 4
basearch = i386
repo = core
mock_config = fedora-4-i386-core

That covers the FC4 i386 packages, and this one is for FC4 x86_64 builds:

[General] 
distro = fedora
target = 4
basearch = x86_64
repo = core
mock_config = fedora-4-x86_64-core

I assume that the distro/target/repo are used to match the builder target with the server target. The basearch tells the builder which architecture to build for. The mock config setting is the file name of the mock config file for that particular distro/arch. In the above example, you would need to have two config files in /etc/mock: fedora-4-i386-core.cfg and fedora-4-x86_64-core.cfg. Those are your standard mock config files and they do not need any special changes to work with plague.

The builder targets are stored in the directory defined in your builder config file:

target_configs_dir = /etc/plague/builder/targets

Please note, that target files have to be suffixed by .cfg