Sha256: 45b480beaae4253b6bfc9d0875723c4427ee1b330c0c417f4d13e4939014e13c

Contents?: true

Size: 1.61 KB

Versions: 45

Compression:

Stored size: 1.61 KB

Contents

"""
This module returns the given status handlers to enable for the
buildbot master.
"""

from buildbot.status import html, words
from buildbot.status.web.authz import Authz
from buildbot.status.web.auth import BasicAuth

def get_status(options):
    """
    Returns a list of status targets for the build master.
    """
    # Load the users that are allowed to perform authenticated
    # actions from the configuration
    auth_users = []
    if options.http_users is not None:
        for pair in options.http_users.split(","):
            user, password = pair.split(":")
            auth_users.append((user, password))

    # Setup the rules for who can do what to the WebStatus
    authz = Authz(
        auth = BasicAuth(auth_users),
        gracefulShutdown = False,
        forceBuild = 'auth',
        forceAllBuilds = 'auth',
        pingBuilder = True,
        stopBuild = 'auth',
        stopAllBuilds = 'auth',
        cancelPendingBuild = 'auth',
        stopChange = 'auth',
        cleanShutdown= False
        )

    # The web status gives us the nice web interface to our buildbot
    web_status = html.WebStatus(
        http_port = options.web_port,
        authz = authz,
        order_console_by_time = True,
        change_hook_dialects=dict(github=True)
        )

    # Hook up an IRC bot into our channel
    irc = words.IRC("irc.freenode.net", "vagrant-ci",
                    channels=[{"channel": "#vagrant"}],
                    notify_events={
                        'exception': 1,
                        'successToFailure': 1,
                        'failureToSuccess': 1})

    return [web_status, irc]

Version data entries

45 entries across 45 versions & 6 rubygems

Version Path
bmhatfield-vagrant-1.0.10 test/buildbot/buildbot_config/master/status.py
bmhatfield-vagrant-1.0.9 test/buildbot/buildbot_config/master/status.py
bmhatfield-vagrant-1.0.8 test/buildbot/buildbot_config/master/status.py
bmhatfield-vagrant-1.0.7 test/buildbot/buildbot_config/master/status.py
vagrantup-1.0.7 test/buildbot/buildbot_config/master/status.py
vagrantup-1.0.6 test/buildbot/buildbot_config/master/status.py
vagrantup-1.0.5 test/buildbot/buildbot_config/master/status.py
vagrantup-1.0.4 test/buildbot/buildbot_config/master/status.py
vagrantup-1.0.3 test/buildbot/buildbot_config/master/status.py
vagrantup-1.0.2 test/buildbot/buildbot_config/master/status.py
vagrantup-1.0.1 test/buildbot/buildbot_config/master/status.py
vagrantup-1.0.0 test/buildbot/buildbot_config/master/status.py
vagrantup-0.9.99.2 test/buildbot/buildbot_config/master/status.py
vagrantup-0.9.99.1 test/buildbot/buildbot_config/master/status.py
vagrantup-0.9.7 test/buildbot/buildbot_config/master/status.py
vagrantup-0.9.6 test/buildbot/buildbot_config/master/status.py
vagrantup-0.9.5 test/buildbot/buildbot_config/master/status.py
vagrantup-0.9.4 test/buildbot/buildbot_config/master/status.py
vagrantup-0.9.3 test/buildbot/buildbot_config/master/status.py
vagrantup-0.9.2 test/buildbot/buildbot_config/master/status.py