[Lsb-messages] /var/www/bzr/lsb/devel/buildbot-config r240: Kill bzr polling completely, and set up the change source receiver.

Jeff Licquia licquia at linuxfoundation.org
Tue May 1 15:41:24 UTC 2012


------------------------------------------------------------
revno: 240
committer: Jeff Licquia <licquia at linuxfoundation.org>
branch nick: buildbot-config
timestamp: Tue 2012-05-01 11:41:24 -0400
message:
  Kill bzr polling completely, and set up the change source receiver.
modified:
  lsb_master.cfg
-------------- next part --------------
=== modified file 'lsb_master.cfg'
--- a/lsb_master.cfg	2012-04-30 18:40:18 +0000
+++ b/lsb_master.cfg	2012-05-01 15:41:24 +0000
@@ -15,6 +15,7 @@
 from buildbot.status import html
 from buildbot.status import words
 from buildbot.status.web.auth import HTPasswdAuth
+from buildbot.changes import pb
 
 import lfbuildbot
 
@@ -241,8 +242,9 @@
 c['slaves'] = []
 slave_password_file = open("/opt/buildbot/slave_pwds")
 for line in slave_password_file:
-    (user, pw) = line.strip().split(":")
+    (user, pw) = line.strip().split(":", 1)
     c['slaves'].append(BuildSlave(user, pw))
+slave_password_file.close()
 
 # to limit to two concurrent builds on a slave, use
 #  c['slaves'] = [BuildSlave("bot1name", "bot1passwd", max_builds=2)]
@@ -260,46 +262,16 @@
 # about source code changes. Any class which implements IChangeSource can be
 # put here: there are several in buildbot/changes/*.py to choose from.
 
-# XXX: Polling effectively disabled (interval set to one week) due to
-#      load/throttling issues on server; need to switch to PbChangeSource.
-
-c['change_source'] = []
-lsb_change_sources = lsb_pkg_subdir_projects.keys() + \
-    [x[1] for x in lsb_packaging_projects if x[1] is not None] + ["appbat"]
-added = []
-for project in lsb_change_sources:
-    if project in added:
-        continue
-    c['change_source'].append(
-        BzrPoller(url="%slsb/devel/%s" % (bzr_toplevel, project),
-                  branch_name="lsb/devel/" + project, poll_interval=604800))
-    for branch in branch_watch_list:
-        if project in branch_watch_list[branch]:
-            c['change_source'].append(
-                BzrPoller(url="%slsb/%s/%s" % (bzr_toplevel, branch, project),
-                          branch_name="lsb/%s/%s" % (branch, project),
-                          poll_interval=604800))
-    added.append(project)
-
-# For example, if you had CVSToys installed on your repository, and your
-# CVSROOT/freshcfg file had an entry like this:
-#pb = ConfigurationSet([
-#    (None, None, None, PBService(userpass=('foo', 'bar'), port=4519)),
-#    ])
-
-# then you could use the following buildmaster Change Source to subscribe to
-# the FreshCVS daemon and be notified on every commit:
-#
-#from buildbot.changes.freshcvs import FreshCVSSource
-#fc_source = FreshCVSSource("cvs.example.com", 4519, "foo", "bar")
-#c['change_source'] = fc_source
-
-# or, use a PBChangeSource, and then have your repository's commit script run
-# 'buildbot sendchange', or use contrib/svn_buildbot.py, or
-# contrib/arch_buildbot.py :
-#
-#from buildbot.changes.pb import PBChangeSource
-#c['change_source'] = PBChangeSource()
+# For the LSB builder, we've moved to a push model, so we only need
+# a push receiver.  We store the user/password data outside this version
+# control repository, as with slave passwords above.
+
+changesrc_password_file = open("/opt/buildbot/changesrc_pwds")
+(changesrc_user, changesrc_pw) = \
+    changesrc_password_file.readline().strip().split(":", 1)
+c['change_source'] = pb.PBChangeSource(user=changesrc_user,
+                                       password=changesrc_pw)
+changesrc_password_file.close()
 
 
 ####### SCHEDULERS



More information about the lsb-messages mailing list