File: configuration.rst

package info (click to toggle)
debomatic 0.40-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 668 kB
  • sloc: python: 1,904; sh: 192; makefile: 37
file content (346 lines) | stat: -rw-r--r-- 10,588 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
Configuration
=============

Configuration file
------------------

Deb-o-Matic configuration file is the most important file within Deb-o-Matic
infrastructure. It defines almost every option needed by Deb-o-Matic.
It is divided into five sections: ``debomatic``, which contains the general
options needed for Deb-o-Matic to work; ``distributions``, which contains all
the details related to the distributions Deb-o-Matic can build package for;
``chroots``, which contains the options related to the creation of the chroots
used to build packages; ``gpg``, which contains the options related to GPG
signature checking; ``modules``, which contains the options related to module
handling.

Other sections are optionally defined by each single module, their details will
be discussed in the :doc:`modules` section.

.. CAUTION::

 Configuration file must be formatted with `Python ConfigParser`_ syntax.

debomatic section
.................

This section is mandatory, Deb-o-Matic refuses to start if one of these
options is missing from the configuration file. Also, Deb-o-Matic needs to be
restarted to pick any change to one of these options.

* ``incoming``

 This option indicates the directory where Deb-o-Matic expects to find source
 packages to build, and in which it will store chroots, build logs, and
 resulting packages.

 Suggested value: ``/incoming``

.. CAUTION::

 Make sure chosen directory exists before launching Deb-o-Matic, otherwise it
 will refuse to start.

* ``architecture``

 This option indicates the architecture to build package for. To build packages
 for the same architecture of the running system, ``system`` can be used
 instead of specifying the exact one.

 Suggested value: ``system``

* ``threads``

 This option indicates the maximum concurrent builds that can be executed. If
 more build tasks are scheduled, they will be blocked until a slot becomes
 available again. More concurrent builds require more CPU cycles, so you may
 want to try different configurations to fit your needs.

 ``threads`` takes an integer as parameter.

 Suggested value: ``3``

* ``inotify``

 This option indicates whether to enable inotify support, or not. inotify will
 notify Deb-o-Matic about the availability of a new task, and will immediately
 start a new thread according to the requested task.

 If ``python3-pyinotify`` is not available, Deb-o-Matic will fall back to a
 timer-based method, where new tasks will be analyzed periodically.

 ``inotify`` takes True or False as parameter.

 Suggested value: ``True``

* ``sleep``

 This option indicates the number of seconds between two consecutive checks for
 new packages or commands to process. This option is only useful if inotify
 support is disabled, or is not available.

 ``sleep`` takes an integer as parameter.

 Suggested value: ``60``

* ``interval``

 This option indicates the number of seconds between two consecutive triggers
 for scheduled actions performed by modules.

 ``interval`` takes an integer as parameter.

 Suggested value: ``3600``

* ``logfile``

 This option indicates which file will be used to store information and warning
 messages issued by Deb-o-Matic during its execution.

 Suggested value: ``/var/log/debomatic.log``

* ``loglevel``

 This option indicates which kind of debug messages will be displayed. There
 are four levels: ``error``, ``warning``, ``info``, and ``debug``.

 Suggested value: ``info``

distributions section
.....................

This section is mandatory, Deb-o-Matic refuses to start if one of these
options is missing from the configuration file. Also, Deb-o-Matic needs to be
restarted to pick any change to one of these options.

* ``list``

 This option indicates the path of the distribution configuration file.
 More on those files will be discussed in the `Distributions file section`_.

 Suggested value: ``/etc/debomatic/distributions``

.. CAUTION::

 Make sure chosen directory exists before launching Deb-o-Matic, otherwise it
 will refuse to start.

* ``blacklist``

 This option indicates a list of distributions that are not allowed to accept
 new packages to build. Files targeted for a blacklisted distribution will be
 automatically deleted.

 Option must define a space-separated distribution names matching the ones
 listed in the `Distributions file section`_.

 Suggested value: ``(blank field)``

* ``mapper``

 This option indicates a list of distributions that, even if they are not
 defined by a distribution file (see `Distributions file section`_), can build
 packages on top of another distribution. This is particularly useful to
 indicate distribution aliases (such as ``sid <=> unstable``) or subsets
 (such as ``vivid-proposed => vivid``).

 Option must define a `Python dictionary`_ where keys are the distributions
 indicated by the packages, and values are the distributions on which build
 packages upon.

 Suggested value: ``{'sid': 'unstable'}``

chroots section
...............

This section is mandatory, Deb-o-Matic refuses to start if one of these
options is missing from the configuration file. Also, Deb-o-Matic needs to be
restarted to pick any change to one of these options.

* ``commands``

 This option indicates the directory where sbuild commands are stored. Commands
 are executable scripts which are processed by sbuild during various build
 phases. Please refer to the sbuild (1) man page for additional details.

 At the moment, Deb-o-Matic provides a script to disable Internet connection
 within the chroot on Linux systems to avoid accessing remote resources during
 the build phase, and another one to increase the speed of unpacking of the 
 dependencies in the chroots.

 Suggested value: ``/usr/share/debomatic/sbuildcommands``

.. CAUTION::

 This directory needs to be bind mounted in the chroot for the scripts to
 be launched correctly. It is possible to do so by adjusting the sbuild
 configuration file.

crossbuild section
..................

This section is optional, Deb-o-Matic will start normally if this section is
missing in the configuration file. Also, Deb-o-Matic needs to be restarted
to pick any change to one of these options.

* ``crossbuild``

 This option indicates whether to enable cross-build support, or not.

* ``hostarchitecture``

 This option indicates which host architecture to use when building source
 packages.

.. CAUTION::

 The architecture must have cross-compilation at compiler lever, otherwise
 it will not be possible to cross-compile source packages.

dpr section
...........

This section is optional, Deb-o-Matic will start normally if this section is
missing in the configuration file. Also, Deb-o-Matic needs to be restarted
to pick any change to one of these options.

* ``dpr``

 This option indicates whether to enable private repositories, or not.

 Suggested value: ``False``

* ``prefix``

 This option indicates the common prefix of all private repositories.

 Suggested value: ``dpr``

* ``repository``

 This option indicates the APT string of a local APT repository which is
 added at build time, useful in combination with the Repository module. The
 string must contain two ``%%(dist)s`` arguments which allows to specify
 dynamically the private repository name, for example:

 *deb http://debomatic.repository/debomatic/%%(dist)s %%(dist)s main*

gpg section
...........

This section is mandatory, Deb-o-Matic refuses to start if one of these
options is missing from the configuration file. Also, Deb-o-Matic needs to be
restarted to pick any change to one of these options.

``gnupg`` package is required for these options to be effective.

* ``gpg``

 This option indicates whether to enable signature checking support, or not. If
 enabled, Deb-o-Matic will delete unsigned files and files with signatures not
 available in its keyring.

 ``gpg`` takes True or False as parameter.

 Suggested value: ``False``

* ``keyring``

 This option indicates the gnupg keyring file in which Deb-o-Matic will look
 for valid and trusted GPG keys.

 Suggested value: ``/etc/debomatic/debomatic.gpg``

.. CAUTION::

 Make sure keyring file exists and is populated with trusted keys if GPG
 support is enabled, otherwise no tasks will be processed.

modules section
...............

This section is mandatory, Deb-o-Matic refuses to start if one of these
options is missing from the configuration file. Also, Deb-o-Matic needs to be
restarted to pick any change to one of these options.

More on modules handling will be discussed in the :doc:`modules` section.

* ``modules``

 This option indicates whether to enable module loading, or not.

 ``modules`` takes True or False as parameter.

 Suggested value: ``True``

* ``path``

 This option indicates the directory where Deb-o-Matic expects to find modules.
 Multiple directories can be listed, separated with a colon (``:``).

 Suggested value: ``/usr/share/debomatic/modules``

* ``threads``

 This option indicates how many modules Deb-o-Matic should launch in parallel.

 ``threads`` takes an integer as parameter.

 Suggested value: ``5``

* ``blacklist``

 This option indicates a list of modules that are not allowed to be executed
 during build process.

 Option must define a space-separated module names matching the ones listed in
 the :doc:`modules` section.

 Suggested value: ``AutoPkgTest Blhc Lintian Mailer Piuparts``

Distributions file
------------------

This file is populated by sections, each of them named after a distribution
to build packages for. Every section can define five options.

* ``suite``

 This option indicates the base suite to create the chroot for. Normally, it is
 equal to its distribution, but there are some exceptions (for instance,
 experimental's suite is unstable).

 This option is mandatory.

* ``mirror``

 This option indicates the mirror site which contains the primary package
 archive of the distribution.

 This option is mandatory.

* ``components``

 This option contains a space-delimited list of components to use.

 This option is mandatory.

* ``extramirrors``

 This option indicates additional mirrors to add in the chroot. More than one
 additional mirror can be defined, separated by a newline.

 This option is optional.

* ``extrapackages``

 This option contains a space-delimited list of additional packages to install
 in the chroot during its creation.

 This option is optional.

.. Links
.. _Python ConfigParser: http://docs.python.org/library/configparser.html
.. _Python dictionary: http://docs.python.org/library/stdtypes.html#mapping-types-dict
.. _Distributions file section: #distributions-file