summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKali Kaneko <kali@leap.se>2013-12-05 22:17:46 -0400
committerKali Kaneko <kali@leap.se>2013-12-05 22:17:46 -0400
commit2f843e4f292629852fa527b85c495d0d4b320843 (patch)
treeb02acafb31236ac9325026636b2334c76c71ea6a
parent3eba8e3a67d947b4d5a0897b2964c3ec0d953a8b (diff)
Update master.cfg, after aeons of inactivity.
Stubbed builders for each leap component. Only added, tentatively, to night builder. Atm only bitmask and mail are correctly configured.
-rw-r--r--master.cfg219
1 files changed, 98 insertions, 121 deletions
diff --git a/master.cfg b/master.cfg
index 875ccce..3abed40 100644
--- a/master.cfg
+++ b/master.cfg
@@ -14,6 +14,8 @@ c = BuildmasterConfig = {}
# a BuildSlave object, specifying a unique slave name and password. The same
# slave name and password must be configured on the slave.
from buildbot.buildslave import BuildSlave
+
+# XXX get actual passwords !
c['slaves'] = [BuildSlave("linux-build-slave", "foobar"),
# BuildSlave("windows-build-slave", "foobar"),
# BuildSlave("mac-build-slave", "foobar")
@@ -61,13 +63,11 @@ from buildbot.changes.gitpoller import GitPoller
from buildbot.changes import pb
c['change_source'] = []
+# XXX how to make the pollers affect to each matching builder?
c['change_source'].append(GitPoller(
- 'git://leap.se/leap_client',
+ 'git://leap.se/bitmask_client',
workdir="gitpoller-workdir", branches=branches, pollinterval=300))
-#c['change_source'].append(pb.PBChangeSource(
-# port=9999, user='laura', passwd='firewalk'))
-
#git poll branch names to automatically build branches to watch.
####### SCHEDULERS
@@ -81,22 +81,19 @@ from buildbot.schedulers.timed import Nightly
from buildbot.changes import filter
c['schedulers'] = []
-c['schedulers'].append(ForceScheduler(
- name="force",
- builderNames=["linux-incremental",
-# "windows-incremental",
-# "mac-incremental"
- ]))
+# XXX this was a good idea, we should bring it to life again...
+#c['schedulers'].append(ForceScheduler(
+# name="force",
+# builderNames=["linux-incremental",
+# ]))
for branch in branches:
c['schedulers'].append(SingleBranchScheduler(
name=branch + "-checkin",
change_filter=filter.ChangeFilter(branch=branch),
treeStableTimer=60,
- builderNames=["linux-incremental",
- "client-linux-quick",
-# "windows-incremental",
-# "mac-incremental"
+ builderNames=[
+ "bitmask-linux-quick",
]))
c['schedulers'].append(Nightly(
@@ -105,9 +102,12 @@ c['schedulers'].append(Nightly(
hour=4,
minute=23,
onlyIfChanged=True,
- builderNames=["client-linux-quick",
-# "windows-full",
-# "mac-full"
+ builderNames=["bitmask-linux-quick",
+ "mail-linux-quick",
+ "keymanager-linux-quick",
+ "mx-linux-quick",
+ "common-linux-quick",
+ "soledad-linux-quick"
]))
####### BUILDERS
@@ -166,10 +166,6 @@ install_virt = ShellCommand(name='Installing Virtual Environment',
description='Installing Virtual Environment',
command=['cp', '-r', '/home/buildslave/venv/.venv', '.'])
-develop_mode = ShellCommand(name='run in develop mode',
- description='yet another workaround for namespace package weirdness',
- command=['pkg/tools/with_venv.sh', 'python', 'setup.py', 'develop'])
-
install_leap = ShellCommand(name='install leap into virtualenv',
description='yet another workaround for namespace package weirdness',
command=['pkg/tools/with_venv.sh', 'python', 'setup.py', 'install'])
@@ -180,73 +176,98 @@ make_resources = ShellCommand(name='compile qt resources',
run_tests = ShellCommand(name='Running Tests', description='Running tests',
command=['pkg/tools/with_venv.sh', './run_tests.sh', '--coverage'])
-#run_tests = ShellCommand(name='Running Tests', description='Running tests',
-# command=['pkg/tools/with_venv.sh', 'nosetests',
-# 'src/leap', '--exclude-dir=src/leap/soledad/',
-# '--exclude-dir=src/leap/common/'])
-
-# XXX will need to introduce xvfb-run again...
-#run_tests = ShellCommand(name='Running Tests', description='Running tests',
-# command=['pkg/tools/with_venv.sh', 'xvfb-run', 'nosetests',
-# '--with-coverage', '--cover-package=leap-client', 'leap'])
-
-#run_mail_tests = ShellCommand(name='Running Mail Tests', description='Running mail tests',
-# command=['pkg/tools/with_venv.sh', 'trial', '--coverage',
-# 'leap.email.smtp.tests'])
-#run_soledad_tests = ShellCommand(name='Running Soledad Tests', description='Running soledad tests',
-# env={'LD_PRELOAD':'/usr/local/lib/libsqlite3.so'},
-# command=['pkg/tools/with_venv.sh', 'nose2', '-v', 'leap.soledad.tests'])
+
+develop_mode = ShellCommand(name='run in develop mode',
+ description='yet another workaround for namespace package weirdness',
+ command=['pkg/tools/with_venvwrapper.sh', 'leap-bitmask', 'python', 'setup.py', 'develop'])
+
+run_tests_venv = ShellCommand(
+ name='Running Tests (venv)',
+ description="Running tests in a virtualenv via virtualenvwrapper",
+ command=['pkg/tools/with_venvwrapper.sh', 'leap-bitmask', 'xvfb-run', './run_tests.sh', '-N', '--coverage'],
+ env={'HOME':'/home/buildslave', 'WORKON_HOME':'/home/buildslave/Virtualenvs',
+ 'VIRTUALENVWRAPPER_HOOK_DIR':'/home/buildslave/Virtualenvs',
+ 'VIRTUALENVWRAPPER_LOG_DIR':'/home/buildslave/Virtualenvs'})
+ # Why the fuck is the wrapper not working???
+ # 'PATH':'/home/buildslave/Virtualenvs/leap-bitmask/bin:/home/buildslave/Virtualenvs/leap-bitmask/local/lib/python2.7/site-packages:/usr/local/bin:/usr/bin:/bin'})
+
+run_tests_py = ShellCommand(
+ name='Running Tests (venv)',
+ description="Running tests in a virtualenv via virtualenvwrapper",
+ command=['pkg/tools/with_venvwrapper.sh', 'leap-bitmask', 'python', 'setup.py', 'test'])
+
run_tox = ShellCommand(name='Running tox', description='Running tox',
command=['pkg/tools/with_venv.sh', 'tox', '-v'])
+
run_pep8 = ShellCommand(name='Running pep8', description='Running pep8',
- command=['pkg/tools/with_venv.sh', 'pep8',
+ command=['pkg/tools/with_venvwrapper.sh', 'leap-bitmask', 'pep8',
'--ignore=E202,W602 --exclude=ui_*,*_rc.py,_version.py --repeat',
'src/leap'])
+
run_coverage = ShellCommand(name='Running coverage', description='Running coverage',
command=['pkg/tools/with_venv.sh', 'coverage', 'html',
'-d', 'docs/covhtml', '-i', '--include=src/leap/*',
'--omit=src/leap/base/tests/*,src/leap/eip/tests/*,src/leap/gui/tests/*,/src/leap/util/tests/*'],
haltOnFailure=True)
+# Linux incremental -----------------------------------------------------------------
f1 = BuildFactory()
-f1.addStep(Git(repourl='git://leap.se/leap_client', mode='incremental', branch='develop'))
-#f1.addStep(cp_script)
-#f1.addStep(skip_pyside)
+f1.addStep(Git(repourl='git://leap.se/bitmask_client', mode='incremental', branch='develop'))
f1.addStep(install_virt)
f1.addStep(run_tests)
-#f1.addStep(run_mail_tests)
-#f1.addStep(run_soledad_tests)
f1.addStep(run_tox)
f1.addStep(run_pep8)
f1.addStep(run_coverage)
f1.addStep(UploadCoverage(name='Uploading coverage', description='Uploading coverage'))
+# -------------------------------------------------------------------------------------
+
+def get_quick_builder(repo_name):
+ """
+ BUILDERS FOR LINUX QUICK
+ """
+ client = mail = soledad = mx = False
+ if repo_name == "bitmask_client":
+ client = True
+ name = "bitmask"
+ elif repo_name == "leap_mail":
+ mail = True
+ name = "mail"
+ elif repo_name == "leap_mx":
+ mx = True
+ name = "mx"
+ elif repo_name == "soledad":
+ soledad = True
+ name = "soledad"
+ elif repo_name == "leap_pycommon":
+ name = "common"
+ else:
+ name = repo_name
+
+ steps = [
+ Git(repourl='https://leap.se/git/%s' % repo_name, mode='full', branch='develop')]
+
+ if client:
+ steps.append(make_resources)
+
+ steps = steps + [
+ develop_mode,
+ run_pep8]
+
+ if client:
+ steps = steps + [
+ run_tests_venv,
+ UploadCoverage(name='Uploading coverage', description='Uploading coverage')]
+ else: # any other
+ steps = steps + [run_tests_py]
-def get_client_quick_builder():
f = BuildFactory()
- # aka "CLIENT LINUX QUICK"
- f.addStep(Git(repourl='git://leap.se/leap_client', mode='full', branch='develop'))
- #f.addStep(Git(repourl='git://github.com/kalikaneko/leap_client.git', mode='full', branch='ci-testing'))
- #f.addStep(cp_script)
- #f.addStep(skip_pyside)
- #f.addStep(add_missing_dep)
- f.addStep(install_virt)
- f.addStep(make_resources)
- #f.addStep(develop_mode)
- #f.addStep(install_leap)
- f.addStep(run_tests)
- #f.addStep(run_mail_tests)
- #f.addStep(run_soledad_tests)
-
- # no tox on quick builder
- #f.addStep(run_tox)
-
- f.addStep(run_pep8)
- #f.addStep(run_coverage)
- f.addStep(UploadCoverage(name='Uploading coverage', description='Uploading coverage'))
- b = {'name': "client-linux-quick",
+ for s in steps:
+ f.addStep(s)
+
+ b = {'name': "%s-linux-quick" % name,
+ 'builddir': "%s_linux_quick" % name,
'slavename': "linux-build-slave",
- 'builddir': "client_linux_quick",
'factory': f,
}
return b
@@ -258,40 +279,9 @@ b1 = {'name': "linux-incremental",
'builddir': "linux-incremental",
'factory': f1,
}
-#b2 = {'name': "windows-incremental",
-# 'slavename': "windows-build-slave",
-# 'builddir': "windows-incremental",
-# 'factory': f1,
-# }
-#b3 = {'name': "mac-incremental",
-# 'slavename': "mac-build-slave",
-# 'builddir': "mac-incremental",
-# 'factory': f1,
-# }
-#b4 = {'name': "linux-full",
-# 'slavename': "linux-build-slave",
-# 'builddir': "linux-full",
-# 'factory': f2,
-# }
-#b5 = {'name': "client-linux-quick",
-# 'slavename': "linux-build-slave",
-# 'builddir': "client_linux_quick",
-# 'factory': get_client_quick_builder(),
-# }
-#b5 = {'name': "windows-full",
-# 'slavename': "windows-build-slave",
-# 'builddir': "windows-full",
-# 'factory': f2,
-# }
-#b6 = {'name': "mac-full",
-# 'slavename': "mac-build-slave",
-# 'builddir': "mac-full",
-# 'factory': f2,
-# }
-
-#c['builders'] = [b1, b2, b3, b4, b5, b6]
-# b5 = get_client_quick_builder()]
-c['builders'] = [b1, get_client_quick_builder()]
+
+repos = ['bitmask_client', 'leap_mail', 'soledad', 'keymanager', 'leap_pycommon', 'leap_mx']
+c['builders'] = [get_quick_builder(repo) for repo in repos]
####### STATUS TARGETS
@@ -311,10 +301,10 @@ authz_cfg=authz.Authz(
gracefulShutdown = False,
forceBuild = 'auth', # use this to test your slave once it is set up
forceAllBuilds = False,
- pingBuilder = False,
- stopBuild = False,
+ pingBuilder = True,
+ stopBuild = 'auth',
stopAllBuilds = False,
- cancelPendingBuild = False,
+ cancelPendingBuild = 'auth',
)
c['status'].append(html.WebStatus(http_port=8010, authz=authz_cfg))
@@ -322,6 +312,8 @@ c['status'].append(html.WebStatus(http_port=8010, authz=authz_cfg))
from buildbot.status import words
+# get this from the config file...
+
BBOT_NICK = "polkabot"
BBOT_CHANNELS = ["#borogoves"]
c['status'].append(words.IRC(
@@ -330,36 +322,21 @@ c['status'].append(words.IRC(
channels=BBOT_CHANNELS,
allowForce=True,
notify_events={
-# 'started': 1,
-# 'finished': 1,
-# 'failure': 1,
+ 'started': 1,
+ 'finished': 1,
+ 'failure': 1,
}
))
-#c['status'].append(words.IRC(host="chat.freenode.net", nick="leap-buildbot",
-# channels=["#leap-dev"]))
####### PROJECT IDENTITY
-# the 'title' string will appear at the top of this buildbot
-# installation's html.WebStatus home page (linked to the
-# 'titleURL') and is embedded in the title of the waterfall HTML page.
-
c['title'] = "LEAP"
c['titleURL'] = "https://leap.se"
-
-# the 'buildbotURL' string should point to the location where the buildbot's
-# internal web server (usually the html.WebStatus page) is visible. This
-# typically uses the port number set in the Waterfall 'status' entry, but
-# with an externally-visible host name which the buildbot cannot figure out
-# without some help.
-
c['buildbotURL'] = "http://lemur.leap.se:8010/"
####### DB URL
c['db'] = {
- # This specifies what database buildbot uses to store its state. You can leave
- # this at its default for all but the largest installations.
'db_url' : "sqlite:///state.sqlite",
}