[users at bb.net] Triggering builds on pull request
David Alves
davidralves at gmail.com
Tue Jan 23 19:46:55 UTC 2018
Hi
I've installed the latest buildbot (with the travis shim) and got it
to mostly work with a private project hosted on github.
I can trigger builds manually (force build)
I setup github/buildbot so that the apps can cross post, and fetch.
I've tested that github can post to bb's webhook, that bb can fetch a
commit. I haven't seen bb post messages to the pull request.
Tailing the log shows that bb is notified when a pull request is
added/updated. No errors are shown.
However this doesn't cause a "try" build to start or a build status
to be posted to the pull request. I do see the changes posted to
Build>Last Changes.
Any help would be greatly appreciated.
Here's a redacted version of my cfg.yml:
env: {}
not_important_files: []
projects:
- branches:
- master
github_token: <token>
name: <proj name>
reporter_context: bb%(prop:TESTS:+/)s%(prop:TESTS)s
repository: git at github.com:<org>/<proj name>.git
shallow: 100
retryFetch: true
mode: "full"
method: "clobber"
stages: []
tags: []
vcs_type: github
treeStableTimer: 1
stages: []
workers:
- id: <id>
name: local-worker
number: 5
type: LocalWorker
and the master.cfg:
from buildbot_travis import TravisConfigurator
c = BuildmasterConfig = {}
TravisConfigurator(BuildmasterConfig, basedir).fromYaml('cfg.yml')
from buildbot_travis import TravisConfigurator
from buildbot_travis.configurator import TravisEndpointMatcher
from buildbot.plugins import util
c['db_url'] = “<conn str>”
c['buildbotNetUsageData'] = None
c['buildbotURL'] = “<local url>”
c['www']['authz'] = util.Authz(
allowRules = [
util.AnyEndpointMatcher(role="admins", defaultDeny=True),
util.AnyControlEndpointMatcher(role="admins"),
],
roleMatchers = [
util.RolesFromGroups(groupPrefix=‘<org name>/‘),
]
)
c['www']['auth'] = util.GitHubAuth(“<client id>”, “<client secret>”,
apiVersion=4, getTeamsMembership=True)
# GitHub webhook receiver
c['www']['change_hook_dialects'] = {
'github': {
'token': ‘<token>’,
'secret': ‘<secret>’,
'strict': True,
}
}
Best
David
More information about the users
mailing list