mozilla-tests/tests_localconfig.py
author Tom Prince <mozilla@hocat.ca>
Wed, 21 Mar 2018 16:44:19 -0600
changeset 15672 36fb6d188727f13e4ff40db1174ffc2ace2ad279
parent 15391 5027326bdd46ce076fb54182edc1e5a30087fd04
permissions -rw-r--r--
Bug 1447781: Disable buildbot builds on comm-central; r?nthomas Since Bug 1447358, comm-central no longer builds on buildbot, so disable the builders. MozReview-Commit-ID: C7B4fOvwqaQ

from buildbot.util import json
from buildbot.status.html import WebStatus
from buildbot import manhole
from thunderbird_config import PLATFORMS as THUNDERBIRD_PLATFORMS

master_config = json.load(open('master_config.json'))

c = BuildmasterConfig = {}
c['slavePortnum'] = master_config.get('pb_port', None)
c['status'] = []

if 'http_port' in master_config:
    c['status'].append(
        WebStatus(http_port=master_config['http_port'], allowForce=True))
    c['buildbotURL'] = 'http://%(hostname)s:%(http_port)i/' % master_config

if 'ssh_port' in master_config:
    c['manhole'] = manhole.PasswordManhole(
        "tcp:%(ssh_port)i:interface=127.0.0.1" % master_config,
        "cltbld", "password")

from config import BRANCHES, PLATFORMS, PROJECTS
import thunderbird_config
# Do everything!
ACTIVE_BRANCHES = BRANCHES.keys()
ACTIVE_THUNDERBIRD_BRANCHES = thunderbird_config.BRANCHES.keys()
if 'limit_fx_platforms' in master_config:
    ACTIVE_PLATFORMS = dict((p, None) for p in master_config['limit_fx_platforms'])
else:
    ACTIVE_PLATFORMS = dict((k, None) for k in PLATFORMS.keys())
if 'limit_fx_slave_platforms' in master_config:
    ACTIVE_FX_SLAVE_PLATFORMS = master_config['limit_fx_slave_platforms']
else:
    ACTIVE_FX_SLAVE_PLATFORMS = {}
if 'limit_tb_platforms' in master_config:
    ACTIVE_THUNDERBIRD_PLATFORMS = dict((p, None) for p in master_config['limit_tb_platforms'])
else:
    ACTIVE_THUNDERBIRD_PLATFORMS = dict((k, None) for k in THUNDERBIRD_PLATFORMS.keys())
ACTIVE_PROJECTS = PROJECTS.keys()

QUEUEDIR = master_config.get("queuedir", "/dev/shm/queue")