Bug 509280 - Add configs for talos staging try using TryTalosFactory. r=anodelman
authorChris AtLee <catlee@mozilla.com>
Tue, 11 Aug 2009 07:51:11 -0400
changeset 1419 ed1259e43959fe3e43d51f2442ba0d1124ee8edc
parent 1418 13f7841c27b965385aa1dba316d83eab063e3fe2
child 1420 fbed901187decda709be8135c3a0c5e2a4ce3c94
push id1
push userroot
push dateWed, 17 Dec 2014 00:18:48 +0000
reviewersanodelman
bugs509280
Bug 509280 - Add configs for talos staging try using TryTalosFactory. r=anodelman
talos-staging-try/config.py
talos-staging-try/master.cfg
talos-staging-try/tinderboxmailnotifier.py
new file mode 100644
--- /dev/null
+++ b/talos-staging-try/config.py
@@ -0,0 +1,35 @@
+from buildbot.steps.shell import WithProperties
+
+GRAPH_CONFIG = ['--resultsServer', 'graphs-stage.mozilla.org', '--resultsLink', '/server/collect.cgi']
+
+TALOS_CONFIG_OPTIONS = GRAPH_CONFIG + ['--activeTests', 'ts:tp:twinopen']
+
+TALOS_CMD = ['python', 'run_tests.py', '--noisy', WithProperties('%(configFile)s')]
+
+SLAVES = {
+    'linux': ["talos-rev1-linux%02i" % x for x in range(1,2)],
+    'xp': ["talos-rev1-xp%02i" % x for x in range(1,2)],
+    'vista': ["talos-rev1-vista%02i" % x for x in range(1,2)],
+    'tiger': ["talos-rev1-tiger%02i" % x for x in range(1,2)],
+    'leopard': ["talos-rev2-leopard%02i" % x for x in range(1,2)],
+}
+
+PLATFORMS = {
+    'macosx': {},
+    'win32': {},
+    'linux': {},
+}
+
+PLATFORMS['macosx']['slave_platforms'] = ['tiger', 'leopard']
+PLATFORMS['macosx']['env_name'] = 'mac-perf'
+PLATFORMS['macosx']['tiger'] = {'name': "MacOSX Darwin 8.8.1"}
+PLATFORMS['macosx']['leopard'] = {'name': "MacOSX Darwin 9.0.0"}
+
+PLATFORMS['win32']['slave_platforms'] = ['xp', 'vista']
+PLATFORMS['win32']['env_name'] = 'win32-perf'
+PLATFORMS['win32']['xp'] = {'name': "WINNT 5.1"}
+PLATFORMS['win32']['vista'] = {'name': "WINNT 6.0"}
+
+PLATFORMS['linux']['slave_platforms'] = ['linux']
+PLATFORMS['linux']['env_name'] = 'linux-perf'
+PLATFORMS['linux']['linux'] = {'name': "Linux"}
new file mode 100644
--- /dev/null
+++ b/talos-staging-try/master.cfg
@@ -0,0 +1,105 @@
+from buildbot.buildslave import BuildSlave
+from buildbot.status import html
+
+import buildbotcustom.process.factory
+reload(buildbotcustom.process.factory)
+from buildbotcustom.process.factory import TryTalosFactory
+
+import buildbotcustom.scheduler
+reload(buildbotcustom.scheduler)
+from buildbotcustom.scheduler import NoMergeMultiScheduler
+
+import config
+reload(config)
+from config import *
+
+# This is the dictionary that the buildmaster pays attention to. We also use
+# a shorter alias to save typing.
+c = BuildmasterConfig = {}
+
+##
+## Misc Config
+##
+
+c['debugPassword'] = "mozilla"
+c['projectName'] = "Talos"
+c['projectURL'] = "http://quality.mozilla.org/en/projects/automation/talos"
+c['buildbotURL'] = "http://talos-staging-master.mozilla.org:8011"
+c['slavePortnum'] = 9011
+
+##
+## Status
+##
+
+c['status'] = []
+c['status'].append(html.WebStatus(http_port=8011, allowForce=True))
+
+from tinderboxmailnotifier import TinderboxMailNotifier
+
+c['status'].append(TinderboxMailNotifier(
+                       fromaddr="talos.buildbot@build.mozilla.org",
+                       tree="MozillaStaging", # move to MozillaTry
+                       extraRecipients=["tinderbox-daemon@tinderbox.mozilla.org",],
+                       relayhost="localhost",
+                       builders=None,
+                       useChangeTime=True,
+                       logCompression="bzip2"))
+
+##
+## Slaves
+##
+
+import BuildSlaves
+reload(BuildSlaves)
+from BuildSlaves import SlavePasswords
+
+c['slaves'] = []
+for platform, names in SLAVES.items():
+    c['slaves'].extend(BuildSlave(name, SlavePasswords[platform], max_builds=1) for name in names)
+
+##
+## Sources
+##
+
+from buildbot.changes.pb import PBChangeSource
+
+c['change_source'] = [PBChangeSource()]
+
+##
+## Builders and Schedulers
+##
+
+c['schedulers'] = []
+
+c['builders'] = []
+
+for platform, platform_config in PLATFORMS.items():
+    for slave_platform in platform_config['slave_platforms']:
+        factory = TryTalosFactory(
+            OS=slave_platform,
+            toolsDir="tools",
+            envName=platform_config['env_name'],
+            workdirBase="../talos-data",
+            buildBranch="Try",
+            branchName="MozillaTest",
+            configOptions=TALOS_CONFIG_OPTIONS,
+            talosCmd=TALOS_CMD,
+            fetchSymbols=True,
+            pageset='',
+            plugins='',
+        )
+        platform_name = platform_config[slave_platform]['name']
+        builder = {
+            'name': "%s try talos" % platform_name,
+            'slavenames': SLAVES[slave_platform],
+            'builddir': "%s" % slave_platform,
+            'factory': factory,
+        }
+        s = NoMergeMultiScheduler(name='%s scheduler' % slave_platform,
+            branch=platform,
+            treeStableTimer=0,
+            builderNames=[builder['name']],
+            numberOfBuildsToTrigger=2,
+        )
+        c['schedulers'].append(s)
+        c['builders'].append(builder)
new file mode 100644
--- /dev/null
+++ b/talos-staging-try/tinderboxmailnotifier.py
@@ -0,0 +1,13 @@
+from buildbot.status import tinderbox
+
+class TinderboxMailNotifier(tinderbox.TinderboxMailNotifier):
+  """
+  Subclass TinderboxMailNotifier to add the slave name to the build.
+  This makes tinderbox happy if we have more than one slave working
+  on one builder.
+  """
+  def buildMessage(self, name, build, results):
+    return tinderbox.TinderboxMailNotifier.buildMessage(self,
+                                                        name + ' ' +
+                                                        build.getSlavename(),
+                                                        build, results)