Last active
September 27, 2016 18:21
-
-
Save AAlvz/d647b09c723b260933f3255790ad9e55 to your computer and use it in GitHub Desktop.
I'm trying to send custom properties to the build.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
log.msg("Found links: " + repr(changedict['links'])) | |
89 del changedict['links'] | |
90 print changedict | |
91 | |
92 d = self.master.data.updates.addChange(**changedict) | |
93 | |
94 # set the return value to None, so we don't get users depending on | |
95 # getting a changeid | |
96 d.addCallback(lambda _: None) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
`buildbot sendchange -m localhost:9999 -a example-user:pass -W me -C default --property=test:myvalue` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- python -*- | |
# ex: set filetype=python: | |
from buildbot.plugins import * | |
# This is a sample buildmaster config file. It must be installed as | |
# 'master.cfg' in your buildmaster's base directory. | |
# This is the dictionary that the buildmaster pays attention to. We also use | |
# a shorter alias to save typing. | |
c = BuildmasterConfig = {} | |
####### WORKERS | |
# The 'workers' list defines the set of recognized workers. Each element is | |
# a Worker object, specifying a unique worker name and password. The same | |
# worker name and password must be configured on the worker. | |
c['workers'] = [worker.Worker("example-slave", "pass")] | |
# 'protocols' contains information about protocols which master will use for | |
# communicating with workers. You must define at least 'port' option that workers | |
# could connect to your master with this protocol. | |
# 'port' must match the value configured into the workers (with their | |
# --master option) | |
c['protocols'] = {'pb': {'port': 9989}} | |
####### CHANGESOURCES | |
# the 'change_source' setting tells the buildmaster how it should find out | |
# about source code changes. Here we point to the buildbot clone of pyflakes. | |
c['change_source'] = [] | |
c['change_source'].append(changes.GitPoller( | |
'git://github.com/buildbot/pyflakes.git', | |
workdir='gitpoller-workdir', branch='master', | |
pollinterval=300)) | |
c['change_source'].append(changes.PBChangeSource(port=9999, user='example-user', passwd='pass')) | |
####### SCHEDULERS | |
# Configure the Schedulers, which decide how to react to incoming changes. In this | |
# case, just kick off a 'runtests' build | |
c['schedulers'] = [] | |
c['schedulers'].append(schedulers.SingleBranchScheduler( | |
name="all", | |
change_filter=util.ChangeFilter(branch='master'), | |
treeStableTimer=None, | |
builderNames=["runtests"])) | |
c['schedulers'].append(schedulers.ForceScheduler( | |
name="force", | |
builderNames=["runtests"])) | |
c['schedulers'].append(schedulers.SingleBranchScheduler( | |
name="waiter", | |
change_filter=util.ChangeFilter(category='default'), | |
builderNames=["runtests"])) | |
c['www'] = dict(port=8020, | |
plugins=dict(waterfall_view={}, console_view={}), | |
change_hook_dialects={ | |
'base': True, | |
'somehook': {'option1':True, | |
'option2':False}}) | |
####### BUILDERS | |
# The 'builders' list defines the Builders, which tell Buildbot how to perform a build: | |
# what steps, and which workers can execute them. Note that any particular build will | |
# only take place on one worker. | |
factory = util.BuildFactory() | |
# check out the source | |
factory.addStep(steps.ShellCommand(command=['echo', 'buildername:',util.Property('test')])) | |
c['builders'] = [] | |
c['builders'].append( | |
util.BuilderConfig(name="runtests", | |
workernames=["example-slave"], | |
factory=factory)) | |
####### STATUS TARGETS | |
# 'status' is a list of Status Targets. The results of each build will be | |
# pushed to these targets. buildbot/status/*.py has a variety to choose from, | |
# like IRC bots. | |
c['status'] = [] | |
####### PROJECT IDENTITY | |
# the 'title' string will appear at the top of this buildbot installation's | |
# home pages (linked to the 'titleURL'). | |
c['title'] = "Pyflakes" | |
c['titleURL'] = "https://launchpad.net/pyflakes" | |
# the 'buildbotURL' string should point to the location where the buildbot's | |
# internal web server is visible. This typically uses the port number set in | |
# the 'www' entry below, but with an externally-visible host name which the | |
# buildbot cannot figure out without some help. | |
c['buildbotURL'] = "http://192.168.33.10/buildbot/" | |
# minimalistic config to activate new web UI | |
c['www'] = dict(port=8020, | |
plugins=dict(waterfall_view={}, console_view={})) | |
####### DB URL | |
c['db'] = { | |
# This specifies what database buildbot uses to store its state. You can leave | |
# this at its default for all but the largest installations. | |
'db_url' : "sqlite:///state.sqlite", | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
buildername: None |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2016-09-27 18:09:32+0000 [Broker,0,127.0.0.1] perspective_addChange called | |
2016-09-27 18:09:32+0000 [Broker,0,127.0.0.1] No files listed in change... bit strange, but not fatal. | |
2016-09-27 18:09:32+0000 [Broker,0,127.0.0.1] {'files': [], 'category': u'default', 'author': u'me', 'repository': u'', 'src': None, 'comments': u'', 'project': u'', 'branch': None, 'when_timestamp': None, 'revlink': u'', 'properties': {'test': 'myvalue'}, 'revision': None} | |
2016-09-27 18:09:32+0000 [-] added change with revision None to database | |
2016-09-27 18:09:32+0000 [-] added buildset 48 to database | |
2016-09-27 18:09:32+0000 [-] starting build <Build runtests> using worker <WorkerForBuilder builder=u'runtests' worker=u'example-slave' state=AVAILABLE> | |
2016-09-27 18:09:32+0000 [-] <Build runtests>.startBuild | |
2016-09-27 18:09:32+0000 [-] acquireLocks(worker <Worker u'example-slave'>, locks []) | |
2016-09-27 18:09:32+0000 [-] starting build <Build runtests>.. pinging the worker <WorkerForBuilder builder=u'runtests' worker=u'example-slave' state=BUILDING> | |
2016-09-27 18:09:32+0000 [-] sending ping | |
2016-09-27 18:09:32+0000 [Broker,0,127.0.0.1] ping finished: success | |
2016-09-27 18:09:33+0000 [-] ShellCommand.startCommand(cmd=<RemoteShellCommand '['echo', 'buildername:', None]'>) | |
2016-09-27 18:09:33+0000 [-] cmd.args = {'workdir': 'build', 'env': None, 'want_stderr': 1, 'logEnviron': True, 'sigtermTime': None, 'logfiles': {}, 'timeout': 1200, 'want_stdout': 1, 'usePTY': None, 'maxTime': None, 'initial_stdin': None} | |
2016-09-27 18:09:33+0000 [-] <RemoteShellCommand '['echo', 'buildername:', None]'>: RemoteCommand.run [0] | |
2016-09-27 18:09:33+0000 [-] command '['echo', 'buildername:', None]' in dir 'build' | |
2016-09-27 18:09:33+0000 [Broker,0,127.0.0.1] <RemoteShellCommand '['echo', 'buildername:', None]'> rc=0 | |
2016-09-27 18:09:33+0000 [-] closing log <buildbot.process.buildstep.SyncLogFileWrapper object at 0x7ff79eaae590> | |
2016-09-27 18:09:33+0000 [-] releaseLocks(<buildbot.steps.shell.ShellCommand object at 0x7ff79eac3210>): [] | |
2016-09-27 18:09:33+0000 [-] step 'shell' complete: success | |
2016-09-27 18:09:33+0000 [-] <Build runtests>: build finished | |
2016-09-27 18:09:33+0000 [-] releaseLocks(<Worker u'example-slave'>): [] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment