From 777529ac80e09423e645522b6b74003850e00599 Mon Sep 17 00:00:00 2001 From: Marcello Stanisci Date: Thu, 22 Dec 2016 14:27:09 +0100 Subject: Allowing the logged user to trigger the force build in Buildbot. In the latest Buildbot, this feature had a new way to be enabled. --- buildbot/master-lonelyslave.cfg | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/buildbot/master-lonelyslave.cfg b/buildbot/master-lonelyslave.cfg index f15e33d..47fe3b4 100644 --- a/buildbot/master-lonelyslave.cfg +++ b/buildbot/master-lonelyslave.cfg @@ -152,9 +152,21 @@ c['status'] = [] from buildbot.plugins import util c['www'] = dict(port=8010, - plugins=dict(waterfall_view={}, - console_view={}), - auth=util.UserPasswordAuth({"marcello": "taler"})) + plugins=dict(waterfall_view={}, console_view={})) + +authz = util.Authz( + allowRules=[ + util.StopBuildEndpointMatcher(role="admins"), + util.ForceBuildEndpointMatcher(role="admins"), + util.RebuildBuildEndpointMatcher(role="admins") + ], + roleMatchers=[ + util.RolesFromUsername(roles=["admins"], usernames=["marcello"]) + ] +) + +c['www']['auth'] = util.UserPasswordAuth({"marcello": "taler"})) +c['www']['authz'] = authz ####### PROJECT IDENTITY c['title'] = "Taler" -- cgit v1.2.3