buildbot_travis
buildbot_travis copied to clipboard
Github webhooks: cannot pass secret (was: Github webhooks are not actually supported)
After more investigating, it seems that it is actually supported, I just used the wrong way to configure secret value.
The right way: in (my master root)/master.cfg, after auto-generated stuff, add the following:
c['www']'change_hook_dialects']['secret'] = 'MyGitHubSecret'
OBSOLETE In (my master root)/master.cfg, after auto-generated stuff, add the following:
c['www']['change_hook_dialects'] = dict(github={'secret': 'MyGitHubSecret'})
# now fix codebaseGenerator which probably works good for polling
# but fails for webhook-produced changes
repo_to_projects = {
'githubuser/reponame': 'projectname',
}
c['codebaseGenerator'] = lambda chdict: repo_to_projects.get(chdict['project'], chdict['project'])
# optionally, make other amendings to auto-generated config