Use https: for buildbot source downloads
[xapian.git] / xapian-maintainer-tools / buildbot / master.cfg
blob1f172f6ab0544d901e598bb97d22d1404f109923
1 # -*- python -*-
2 # ex: set syntax=python:
4 import os
6 xapian_git_root = 'https://git.xapian.org/xapian'
7 tarball_root = "https://oligarchy.co.uk/xapian/trunk/"
8 tarball_root_stable = "https://oligarchy.co.uk/xapian/branches/1.2/"
10 # This is the dictionary that the buildmaster pays attention to. We also use
11 # a shorter alias to save typing.
12 c = BuildmasterConfig = {}
14 ####### BUILDSLAVES
16 # The 'slaves' list defines the set of recognized buildslaves. Each element is
17 # a BuildSlave object, specifying a unique slave name and password.  The same
18 # slave name and password must be configured on the slave.
19 from buildbot.buildslave import BuildSlave
21 class MySlave(BuildSlave):
22     def __init__(self, name, **kwargs):
23         password = self.get_pass(name)
24         BuildSlave.__init__(self, name, password, **kwargs)
26     def get_pass(self, name):
27         # get the password based on the name
28         path = os.path.join(os.path.dirname(__file__), "%s.pass" % name)
29         pw = open(path).read().strip()
30         return pw
32 c['slaves'] = [MySlave(h, max_builds=1) for h in (
33         "linux_i686_earlgrey",
34         "macos_broteas",
35         "gentoo_jbergstroem",
36         "linux_ojwb",
37         "debian_hppa_gcc61",
38         "fedora_ppc64_gcc110",
39         "aix_gcc111",
40         "unstable11s.opencsw",
41     )]
43 # 'slavePortnum' defines the TCP port to listen on for connections from slaves.
44 # This must match the value configured into the buildslaves (with their
45 # --master option)
46 c['slavePortnum'] = 9989
48 ####### CHANGESOURCES
50 # the 'change_source' setting tells the buildmaster how it should find out
51 # about source code changes.
53 c['change_source'] = []
55 from buildbot.changes.gitpoller import GitPoller
56 c['change_source'].append(GitPoller(
57     repourl=xapian_git_root,
58     pollinterval=60
61 from tarsource import TarPoller
62 c['change_source'].append(TarPoller(tarball_root, branch='tar', archives=('xapian-core', 'xapian-omega', 'xapian-bindings'), pollinterval=60))
63 c['change_source'].append(TarPoller(tarball_root_stable, branch='tar', archives=('xapian-core', 'xapian-omega', 'xapian-bindings'), pollinterval=60))
65 ####### SCHEDULERS
67 # Configure the Schedulers, which decide how to react to incoming changes.
69 from buildbot.schedulers.basic import SingleBranchScheduler
70 c['schedulers'] = []
72 c['schedulers'].append(SingleBranchScheduler(
73     name="xapian_git_quick",
74     branch='trunk',
75     builderNames=['xapian head update linux amd64'],
76     treeStableTimer=70))
78 c['schedulers'].append(SingleBranchScheduler(
79     name="xapian_tar",
80     branch="tar",
81     builderNames=['xapian tar macos', "xapian tar gentoo", "xapian tar linux ojwb", "xapian tar mingw-cross", "xapian tar mingw64-cross"],
82     treeStableTimer=0))
83 c['schedulers'].append(SingleBranchScheduler(
84     name="xapian_tar_weekly",
85     branch="tar",
86     builderNames=["xapian tar fedora ppc64", "xapian tar debian hppa", "xapian tar aix", "xapian tar aix xlc", "xapian tar gentoo nochert", "xapian tar gentoo noglass",
87         'tar solaris11s',
88         'tar solaris11s suncc',
89         'stable tar solaris11s',
90         'stable tar solaris11s suncc'
91     ],
92     treeStableTimer=7*24*60*60))
94 #c['schedulers'].append(SingleBranchScheduler(
95 #    name="xapian_git_slow",
96 #    branch='trunk',
97 #    treeStableTimer=15*60))
98 c['schedulers'].append(SingleBranchScheduler(
99     name="xapian_git_1hr",
100     branch='trunk',
101     builderNames=['xapian head update log assert linux amd64',
102                   'xapian head update log assert macos',
103                   'xapian head update macos',
104                   'xapian head update clang linux amd64'],
105     treeStableTimer=60*60))
106 c['schedulers'].append(SingleBranchScheduler(
107     name="xapian_git_2hr",
108     branch='trunk',
109     builderNames=['xapian head update glibcxxdebug linux amd64'],
110     treeStableTimer=60*60))
111 c['schedulers'].append(SingleBranchScheduler(
112     name="xapian_git_3hr",
113     branch='trunk',
114     builderNames=['xapian head update linux i686'],
115     treeStableTimer=3*60*60))
116 c['schedulers'].append(SingleBranchScheduler(
117     name="xapian_git_4h",
118     branch='trunk',
119     builderNames=['xapian head update assert linux amd64'],
120     treeStableTimer=4*60*60))
121 c['schedulers'].append(SingleBranchScheduler(
122     name="xapian_git_5h",
123     branch='trunk',
124     builderNames=['xapian head update log linux amd64',
125                   'xapian head update -Os linux amd64',
126                   'stable tar assert linux amd64',
127                   'stable tar log linux amd64',
128                   'stable tar glibcxxdebug linux amd64',
129                   'stable tar log assert linux amd64',
130                   'stable tar macos',
131                   'stable tar gentoo',
132                   'stable tar gentoo nobrass',
133                   'stable tar gentoo nochert',
134                   'stable tar gentoo noflint',
135                   'stable tar linux ojwb',
136                   'stable tar clang linux amd64',
137                   'stable tar fedora ppc64',
138                   'stable tar debian hppa',
139                   'stable tar aix',
140                   'stable tar aix xlc',
141                   'stable tar mingw-cross',
142                   'stable tar mingw64-cross',
143                   ],
144     treeStableTimer=5*60*60))
145 #c['schedulers'].append(SingleBranchScheduler(
146 #    name="xapian_git_veryslow4",
147 #    branch='trunk',
148 #    treeStableTimer=6*60*60))
149 c['schedulers'].append(SingleBranchScheduler(
150     name="xapian_git_veryslow5",
151     branch='trunk',
152     builderNames=['xapian head update valgrind linux amd64',
153                   'xapian head update lcov linux amd64'],
154     treeStableTimer=7*60*60))
156 ####### BUILDERS
158 # The 'builders' list defines the Builders, which tell Buildbot how to perform a build:
159 # what steps, and which slaves can execute them.  Note that any particular build will
160 # only take place on one slave.
162 from buildbot.config import BuilderConfig
163 from xapian_factories import *
165 c['builders'] = []
167 for builder in [
168     {
169     'name': 'xapian head update linux amd64',
170     'slavename': 'linux_ojwb',
171     'factory': git_updated_factory2(xapian_git_root, ["--without-java"]),
172     },
173     {
174     'name': 'xapian head update assert linux amd64',
175     'slavename': 'linux_ojwb',
176     'factory': git_debug_updated_factory(xapian_git_root, ["--enable-assertions=yes", "--without-java"]),
177     },
178     {
179     'name': 'stable tar assert linux amd64',
180     'slavename': 'linux_ojwb',
181     'factory': tarball_updated_factory(tarball_root_stable, configure_opts=["--enable-assertions=yes", "--without-java"]),
182     },
183     {
184     'name': 'xapian head update log linux amd64',
185     'slavename': 'linux_ojwb',
186     'factory': git_debug_updated_factory(xapian_git_root, ["--enable-log=yes", "--without-java"]),
187     },
188     {
189     'name': 'stable tar log linux amd64',
190     'slavename': 'linux_ojwb',
191     'factory': tarball_updated_factory(tarball_root_stable, configure_opts=["--enable-log=yes", "--without-java"]),
192     },
193     {
194     'name': 'xapian head update glibcxxdebug linux amd64',
195     'slavename': 'linux_ojwb',
196     'factory': git_debug_updated_factory(xapian_git_root, ["CPPFLAGS=-D_GLIBCXX_DEBUG", "--without-java"]),
197     },
198     {
199     'name': 'stable tar glibcxxdebug linux amd64',
200     'slavename': 'linux_ojwb',
201     'factory': tarball_updated_factory(tarball_root_stable, configure_opts=["CPPFLAGS=-D_GLIBCXX_DEBUG", "--without-java"]),
202     },
203     {
204     'name': 'xapian head update log assert linux amd64',
205     'slavename': 'linux_ojwb',
206     'factory': git_debug_updated_factory(xapian_git_root, ["--enable-assertions=yes", "--enable-log=yes", "--without-java"]),
207     },
208     {
209     'name': 'stable tar log assert linux amd64',
210     'slavename': 'linux_ojwb',
211     'factory': tarball_updated_factory(tarball_root_stable, configure_opts=["--enable-assertions=yes", "--enable-log=yes", "--without-java"]),
212     },
214     {
215     'name': 'xapian head update linux i686',
216     'slavename': 'linux_i686_earlgrey',
217     'factory': git_updated_factory(xapian_git_root),
218     },
220     {
221     'name': 'xapian head update macos',
222     'slavename': 'macos_broteas',
223     'factory': git_updated_factory(xapian_git_root, usedocs=False),
224     },
225     {
226     'name': 'xapian head update log assert macos',
227     'slavename': 'macos_broteas',
228     'factory': git_debug_updated_factory(xapian_git_root, ["--enable-assertions=yes", "--enable-log=yes", "--without-java"]),
229     },
230     {
231     'name': "xapian head update valgrind linux amd64",
232     'slavename': 'linux_ojwb',
233     'factory': git_updated_valgrind_factory(xapian_git_root, ["--without-java"]),
234     },
235     {
236     'name': "xapian head update lcov linux amd64",
237     'slavename': 'linux_ojwb',
238     'factory': git_updated_lcov_factory(xapian_git_root),
239     },
240     {
241     'name': "xapian tar macos",
242     'slavename': 'macos_broteas',
243     'factory': tarball_updated_factory(tarball_root),
244     },
245     {
246     'name': 'stable tar macos',
247     'slavename': 'macos_broteas',
248     'factory': tarball_updated_factory(tarball_root_stable),
249     },
250     {
251     'name': "xapian tar gentoo",
252     'slavename': 'gentoo_jbergstroem',
253     'factory': tarball_updated_factory(tarball_root, configure_opts=["--without-java", "PYTHON=/usr/bin/python2"]),
254     },
255     {
256     'name': 'stable tar gentoo',
257     'slavename': 'gentoo_jbergstroem',
258     'factory': tarball_updated_factory(tarball_root_stable, configure_opts=["--without-java"]),
259     },
260     {
261     'name': "xapian tar gentoo noglass",
262     'slavename': 'gentoo_jbergstroem',
263     'factory': tarball_updated_factory(tarball_root, configure_opts=["--without-java", "--disable-backend-glass"]),
264     },
265     {
266     'name': 'stable tar gentoo nobrass',
267     'slavename': 'gentoo_jbergstroem',
268     'factory': tarball_updated_factory(tarball_root_stable, configure_opts=["--without-java", "--disable-backend-brass"]),
269     },
270     {
271     'name': "xapian tar gentoo nochert",
272     'slavename': 'gentoo_jbergstroem',
273     'factory': tarball_updated_factory(tarball_root, configure_opts=["--without-java", "--disable-backend-chert"]),
274     },
275     {
276     'name': 'stable tar gentoo nochert',
277     'slavename': 'gentoo_jbergstroem',
278     'factory': tarball_updated_factory(tarball_root_stable, configure_opts=["--without-java", "--disable-backend-chert"]),
279     },
280     {
281     'name': 'stable tar gentoo noflint',
282     'slavename': 'gentoo_jbergstroem',
283     'factory': tarball_updated_factory(tarball_root_stable, configure_opts=["--without-java", "--disable-backend-flint"]),
284     },
285     {
286     'name': "xapian tar linux ojwb",
287     'slavename': 'linux_ojwb',
288     'factory': tarball_updated_factory(tarball_root),
289     },
290     {
291     'name': 'stable tar linux ojwb',
292     'slavename': 'linux_ojwb',
293     'factory': tarball_updated_factory(tarball_root_stable),
294     },
295     {
296     'name': 'xapian head update -Os linux amd64',
297     'slavename': 'linux_ojwb',
298     'factory': git_debug_updated_factory(xapian_git_root, ["CFLAGS=-Os", "CXXFLAGS=-Os"]),
299     },
300     {
301     'name': 'xapian head update clang linux amd64',
302     'slavename': 'linux_ojwb',
303     'factory': git_debug_updated_factory(xapian_git_root, ["CC=clang", "CXX=clang++"]),
304     },
305     {
306     'name': 'stable tar clang linux amd64',
307     'slavename': 'linux_ojwb',
308     'factory': tarball_updated_factory(tarball_root_stable, configure_opts=["CC=clang", "CXX=clang++"]),
309     },
310     {
311     'name': "xapian tar fedora ppc64",
312     'slavename': 'fedora_ppc64_gcc110',
313     'factory': tarball_updated_factory(tarball_root),
314     },
315     {
316     'name': 'stable tar fedora ppc64',
317     'slavename': 'fedora_ppc64_gcc110',
318     'factory': tarball_updated_factory(tarball_root_stable),
319     },
320     {
321     'name': "xapian tar debian hppa",
322     'slavename': 'debian_hppa_gcc61',
323     'factory': tarball_updated_factory(tarball_root),
324     },
325     {
326     'name': "stable tar debian hppa",
327     'slavename': 'debian_hppa_gcc61',
328     'factory': tarball_updated_factory(tarball_root_stable),
329     },
330     # Perl bindings fail to build on AIX due to compiler error - not sure
331     # what's going on there.
332     # /usr/opt/perl5/lib/5.10.1/aix-thread-multi/CORE/reentr.h:780:21: error: field '_srandom_struct' has incomplete type
333     #  struct random_data _srandom_struct;
334     {
335     'name': "xapian tar aix",
336     'slavename': 'aix_gcc111',
337     'factory': tarball_updated_factory(tarball_root, omega=False, configure_opts=['--without-perl']),
338     },
339     {
340     'name': "stable tar aix",
341     'slavename': 'aix_gcc111',
342     'factory': tarball_updated_factory(tarball_root_stable, omega=False, configure_opts=['--without-perl']),
343     },
344     {
345     'name': "xapian tar aix xlc",
346     'slavename': 'aix_gcc111',
347     'factory': tarball_updated_factory(tarball_root, omega=False, configure_opts=['CXX=/usr/bin/xlC', 'CC=/usr/bin/xlc']),
348     },
349     {
350     'name': "stable tar aix xlc",
351     'slavename': 'aix_gcc111',
352     'factory': tarball_updated_factory(tarball_root_stable, omega=False, configure_opts=['CXX=/usr/bin/xlC', 'CC=/usr/bin/xlc']),
353     },
354     {
355     'name': "xapian tar mingw-cross",
356     'slavename': 'linux_ojwb',
357     # MXE doesn't build shared libraries; bindings don't cross-compile well.
358     'factory': tarball_updated_factory(tarball_root, nocheck=True, bindings=False, configure_opts=["--disable-shared", "--host=i686-pc-mingw32", "CC=/opt/mxe/usr/bin/i686-pc-mingw32-gcc", "CXX=/opt/mxe/usr/bin/i686-pc-mingw32-g++"]),
359     'env':{'PATH': '/opt/mxe/usr/bin:/usr/lib/ccache:/usr/bin:/bin'},
360     },
361     {
362     'name': "xapian tar mingw64-cross",
363     'slavename': 'linux_ojwb',
364     # MXE doesn't build shared libraries; bindings don't cross-compile well.
365     'factory': tarball_updated_factory(tarball_root, nocheck=True, bindings=False, configure_opts=["--disable-shared", "--host=x86_64-w64-mingw32", "CC=/opt/mxe/usr/bin/x86_64-w64-mingw32-gcc", "CXX=/opt/mxe/usr/bin/x86_64-w64-mingw32-g++", "CPPFLAGS=-DMINGW_HAS_SECURE_API"]),
366     'env':{'PATH': '/opt/mxe/usr/bin:/usr/lib/ccache:/usr/bin:/bin'},
367     },
368     {
369     'name': "stable tar mingw-cross",
370     'slavename': 'linux_ojwb',
371     # MXE doesn't build shared libraries; bindings don't cross-compile well.
372     'factory': tarball_updated_factory(tarball_root_stable, nocheck=True, bindings=False, configure_opts=["--disable-shared", "--host=i686-pc-mingw32", "CC=/opt/mxe/usr/bin/i686-pc-mingw32-gcc", "CXX=/opt/mxe/usr/bin/i686-pc-mingw32-g++"]),
373     'env':{'PATH': '/opt/mxe/usr/bin:/usr/lib/ccache:/usr/bin:/bin'},
374     },
375     {
376     'name': "stable tar mingw64-cross",
377     'slavename': 'linux_ojwb',
378     # MXE doesn't build shared libraries; bindings don't cross-compile well.
379     'factory': tarball_updated_factory(tarball_root_stable, nocheck=True, bindings=False, configure_opts=["--disable-shared", "--host=x86_64-w64-mingw32", "CC=/opt/mxe/usr/bin/x86_64-w64-mingw32-gcc", "CXX=/opt/mxe/usr/bin/x86_64-w64-mingw32-g++", "CPPFLAGS=-DMINGW_HAS_SECURE_API"]),
380     'env':{'PATH': '/opt/mxe/usr/bin:/usr/lib/ccache:/usr/bin:/bin'},
381     },
382     {
383     'name': 'tar solaris11s',
384     'slavename': 'unstable11s.opencsw',
385     'factory': tarball_updated_factory(tarball_root, omega=False),
386     },
387     {
388     'name': 'tar solaris11s suncc',
389     'slavename': 'unstable11s.opencsw',
390     'factory': tarball_updated_factory(tarball_root, omega=False, configure_opts=["CC=/opt/solarisstudio12.3/bin/cc", "CXX=/opt/solarisstudio12.3/bin/CC"]),
391     },
392     {
393     'name': 'stable tar solaris11s',
394     'slavename': 'unstable11s.opencsw',
395     'factory': tarball_updated_factory(tarball_root_stable, omega=False),
396     },
397     {
398     'name': 'stable tar solaris11s suncc',
399     'slavename': 'unstable11s.opencsw',
400     'factory': tarball_updated_factory(tarball_root_stable, omega=False, configure_opts=["CC=/opt/solarisstudio12.3/bin/cc", "CXX=/opt/solarisstudio12.3/bin/CC"]),
401     },
403     name = builder['name']
404     if name.find('stable') != -1:
405         builder['category'] = 'stable'
406     else:
407         builder['category'] = 'dev'
408     c['builders'].append(BuilderConfig(**builder))
410 ### FIXME: more builders...
412 ####### STATUS TARGETS
414 # 'status' is a list of Status Targets. The results of each build will be
415 # pushed to these targets. buildbot/status/*.py has a variety to choose from,
416 # including web pages, email senders, and IRC bots.
418 c['status'] = []
420 from buildbot.status import html
421 c['status'].append(html.WebStatus(http_port=8010))
423 # from buildbot.status import mail
424 # c['status'].append(mail.MailNotifier(fromaddr="buildbot@localhost",
425 #                                      extraRecipients=["builds@example.com"],
426 #                                      sendToInterestedUsers=False))
428 #from buildbot.status import words
429 import words # Use our own fixed version
430 path = os.path.join(os.path.dirname(__file__), "password.irc")
431 irc_password = open(path).read().strip()
432 c['status'].append(words.IRC(host="irc.freenode.net", nick="xapian-buildbot",
433                              password=irc_password,
434                              allowForce=True,
435                              channels=["#xapian-devel"]))
437 # from buildbot.status import client
438 # c['status'].append(client.PBListener(9988))
441 ####### DEBUGGING OPTIONS
443 # if you set 'debugPassword', then you can connect to the buildmaster with
444 # the diagnostic tool in contrib/debugclient.py . From this tool, you can
445 # manually force builds and inject changes, which may be useful for testing
446 # your buildmaster without actually committing changes to your repository (or
447 # before you have a functioning 'change_source' set up). The debug tool uses the
448 # same port number as the slaves do: 'slavePortnum'.
450 #c['debugPassword'] = "debugpassword"
452 # if you set 'manhole', you can ssh into the buildmaster and get an
453 # interactive python shell, which may be useful for debugging buildbot
454 # internals. It is probably only useful for buildbot developers. You can also
455 # use an authorized_keys file, or plain telnet.
456 #from buildbot import manhole
457 #c['manhole'] = manhole.PasswordManhole("tcp:9999:interface=127.0.0.1",
458 #                                       "admin", "password")
461 ####### PROJECT IDENTITY
463 # the 'title' string will appear at the top of this buildbot
464 # installation's html.WebStatus home page (linked to the
465 # 'titleURL') and is embedded in the title of the waterfall HTML page.
467 c['title'] = "Xapian"
468 c['titleURL'] = "https://xapian.org/"
470 # the 'buildbotURL' string should point to the location where the buildbot's
471 # internal web server (usually the html.WebStatus page) is visible. This
472 # typically uses the port number set in the Waterfall 'status' entry, but
473 # with an externally-visible host name which the buildbot cannot figure out
474 # without some help.
476 c['buildbotURL'] = "https://buildbot.xapian.org/"