Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100755 337 lines (271 sloc) 13.819 kB
a0f8235 @whimboo Add MPL license and shebang
whimboo authored
1 #!/usr/bin/env python
2
b4123c8 @whimboo Move license to MPL 2.0
whimboo authored
3 # This Source Code Form is subject to the terms of the Mozilla Public
4 # License, v. 2.0. If a copy of the MPL was not distributed with this
5 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
a0f8235 @whimboo Add MPL license and shebang
whimboo authored
6
2a54eed @whimboo Add support for Mozilla Pulse Guardian (#518)
whimboo authored
7 import ConfigParser
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
8 import copy
c3a9e4c @whimboo Initial commit
whimboo authored
9 import json
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
10 import logging
b46ca07 @whimboo Add debug possibilities
whimboo authored
11 import optparse
d057ba2 @whimboo fix import error
whimboo authored
12 import os
fed11bf @whimboo Make sure the applabel is unique per host to prevent queue corruption
whimboo authored
13 import socket
8c24448 @whimboo Slow down Jenkins API calls when creating ondemand jobs (#364)
whimboo authored
14 import time
c3a9e4c @whimboo Initial commit
whimboo authored
15
16 import jenkins
2a54eed @whimboo Add support for Mozilla Pulse Guardian (#518)
whimboo authored
17
18 from mozillapulse.config import PulseConfiguration
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
19 from pulsebuildmonitor import start_pulse_monitor
c3a9e4c @whimboo Initial commit
whimboo authored
20
21
9ee67a0 @whimboo Create separate config files for daily and l10n tests
whimboo authored
22 class NotFoundException(Exception):
23 """Exception for a resource not being found (e.g. no logs)"""
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
24
9ee67a0 @whimboo Create separate config files for daily and l10n tests
whimboo authored
25 def __init__(self, message, location):
26 self.location = location
27 Exception.__init__(self, ': '.join([message, location]))
28
29
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
30 class JSONFile:
c3a9e4c @whimboo Initial commit
whimboo authored
31
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
32 def __init__(self, filename):
c36ce98 @whimboo Only check if file exists when reading from JSON file
whimboo authored
33 self.filename = os.path.abspath(filename)
5f4bf09 @whimboo Use a regular expression for the routing key to determine if a notifi…
whimboo authored
34
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
35 def read(self):
c36ce98 @whimboo Only check if file exists when reading from JSON file
whimboo authored
36 if not os.path.isfile(self.filename):
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
37 raise NotFoundException('Specified file cannot be found.',
38 self.filename)
c36ce98 @whimboo Only check if file exists when reading from JSON file
whimboo authored
39
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
40 try:
41 f = open(self.filename, 'r')
42 return json.loads(f.read())
43 finally:
44 f.close()
3f395ca @whimboo Update platform map, add some Tier 1 locales, and update handling of …
whimboo authored
45
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
46 def write(self, data):
246c267 @whimboo Better exception handling for writing log files
whimboo authored
47 folder = os.path.dirname(self.filename)
48 if not os.path.exists(folder):
49 os.makedirs(folder)
50
b46ca07 @whimboo Add debug possibilities
whimboo authored
51 try:
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
52 f = open(self.filename, 'w')
b46ca07 @whimboo Add debug possibilities
whimboo authored
53 f.write(json.dumps(data))
54 finally:
55 f.close()
56
9ee67a0 @whimboo Create separate config files for daily and l10n tests
whimboo authored
57
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
58 class Automation:
59
2a54eed @whimboo Add support for Mozilla Pulse Guardian (#518)
whimboo authored
60 def __init__(self, configfile, pulse_authfile, debug, log_folder, logger,
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
61 message=None, display_only=False):
d9c0858 @whimboo Issue #62: Pulse consumer timed out in amqplib with socket.error. r=j…
whimboo authored
62
2a54eed @whimboo Add support for Mozilla Pulse Guardian (#518)
whimboo authored
63 self.config = JSONFile(configfile).read()
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
64 self.debug = debug
65 self.log_folder = log_folder
66 self.logger = logger
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
67 self.display_only = display_only
54c1a18 @whimboo Add feature to show build properties out of the pulse notificiation
whimboo authored
68 self.test_message = message
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
69
70 self.jenkins = jenkins.Jenkins(self.config['jenkins']['url'],
71 self.config['jenkins']['username'],
72 self.config['jenkins']['password'])
73
2a54eed @whimboo Add support for Mozilla Pulse Guardian (#518)
whimboo authored
74 # When a local pulse message is used, return immediately
54c1a18 @whimboo Add feature to show build properties out of the pulse notificiation
whimboo authored
75 if self.test_message:
76 data = JSONFile(self.test_message).read()
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
77 self.on_build(data)
d9c0858 @whimboo Issue #62: Pulse consumer timed out in amqplib with socket.error. r=j…
whimboo authored
78 return
79
2a54eed @whimboo Add support for Mozilla Pulse Guardian (#518)
whimboo authored
80 # Load Pulse Guardian authentication from config file
81 if not os.path.exists(pulse_authfile):
82 print 'Config file for Mozilla Pulse does not exist!'
83 return
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
84
2a54eed @whimboo Add support for Mozilla Pulse Guardian (#518)
whimboo authored
85 pulse_cfgfile = ConfigParser.ConfigParser()
86 pulse_cfgfile.read(pulse_authfile)
87 pulse_cfg = PulseConfiguration.read_from_config(pulse_cfgfile)
88
ebe8b45 @whimboo Remove duplicated user info from pulse applabel (#521)
whimboo authored
89 label = '%s/%s' % (socket.getfqdn(), self.config['pulse']['applabel'])
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
90 self.monitor = start_pulse_monitor(buildCallback=self.on_build,
91 testCallback=None,
92 pulseCallback=self.on_debug if self.debug else None,
93 label=label,
94 trees=self.config['pulse']['branches'],
95 platforms=self.config['pulse']['platforms'],
96 products=self.config['pulse']['products'],
97 buildtypes=None,
98 tests=None,
99 buildtags=self.config['pulse']['tags'],
2a54eed @whimboo Add support for Mozilla Pulse Guardian (#518)
whimboo authored
100 logger=self.logger,
101 pulse_cfg=pulse_cfg)
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
102
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
103 try:
104 while self.monitor.is_alive():
105 self.monitor.join(1.0)
106 except (KeyboardInterrupt, SystemExit):
107 self.logger.info('Shutting down Pulse listener')
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
108
0365a7f @whimboo Add platform coverage per branch. Fixes issue #2
whimboo authored
109 def generate_job_parameters(self, testrun, node, platform, build_properties):
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
110 # Create parameter map from Pulse to Jenkins properties
111 map = self.config['testrun']['jenkins_parameter_map']
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
112 parameter_map = copy.deepcopy(map['default'])
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
113 if testrun in map:
114 for key in map[testrun]:
115 parameter_map[key] = map[testrun][key]
116
117 # Create parameters and fill in values as given by the map
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
118 parameters = {}
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
119 for entry in parameter_map:
120 value = None
121
122 if 'key' in parameter_map[entry]:
123 # A key means we have to retrieve a value from a dict
124 value = build_properties.get(parameter_map[entry]['key'],
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
125 parameter_map[entry].get('default'))
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
126 elif 'value' in parameter_map[entry]:
127 # A value means we have an hard-coded value
128 value = parameter_map[entry]['value']
129
130 if 'transform' in parameter_map[entry]:
131 # A transformation method has to be called
132 method = parameter_map[entry]['transform']
133 value = Automation.__dict__[method](self, value)
134
135 parameters[entry] = value
136
0365a7f @whimboo Add platform coverage per branch. Fixes issue #2
whimboo authored
137 # Add node and mozmill environment information
138 parameters['NODES'] = node
e3f81ee @davehunt Only run endurance tests on nodes with the 'endurance' label. Fixes i…
davehunt authored
139 if testrun in ['endurance']:
140 parameters['NODES'] = ' && '.join([parameters['NODES'], testrun])
0365a7f @whimboo Add platform coverage per branch. Fixes issue #2
whimboo authored
141 parameters['ENV_PLATFORM'] = self.get_mozmill_environment_platform(platform)
88489ac @whimboo Add 'NodeLabel Parameter' Plugin and update testruns to get executed …
whimboo authored
142
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
143 return parameters
144
0365a7f @whimboo Add platform coverage per branch. Fixes issue #2
whimboo authored
145 def get_mozmill_environment_platform(self, platform):
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
146 # Map to translate the platform to the Mozmill environment platform
147 ENVIRONMENT_PLATFORM_MAP = {'linux': 'linux',
148 'linux64': 'linux',
149 'mac': 'mac',
150 'win32': 'windows',
151 'win64': 'windows'}
0365a7f @whimboo Add platform coverage per branch. Fixes issue #2
whimboo authored
152
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
153 return ENVIRONMENT_PLATFORM_MAP[platform]
0365a7f @whimboo Add platform coverage per branch. Fixes issue #2
whimboo authored
154
155 def get_platform_identifier(self, platform):
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
156 # Map to translate platform ids from Pulse to Mozmill / Firefox
157 PLATFORM_MAP = {'linux': 'linux',
158 'linux64': 'linux64',
159 'macosx': 'mac',
160 'macosx64': 'mac',
161 'win32': 'win32',
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
162 'win64': 'win64'}
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
163
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
164 return PLATFORM_MAP[platform]
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
165
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
166 def on_build(self, data):
167 # From: http://hg.mozilla.org/build/buildbot/file/08b7c51d2962/master/buildbot/status/builder.py#l25
168 results = ['success', 'warnings', 'failure', 'skipped', 'exception', 'retry']
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
169
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
170 log_data = {'BRANCH': data['tree'],
171 'BUILD_ID': data['buildid'],
172 'KEY': data['key'],
173 'LOCALE': data['locale'],
174 'PRODUCT': data['product'],
175 'PLATFORM': data['platform'],
176 'STATUS': results[data['status']],
177 'TIMESTAMP': data['timestamp'],
178 'VERSION': data['version']}
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
179
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
180 # Output build information to the console
181 self.logger.info('%(TIMESTAMP)s - %(PRODUCT)s %(VERSION)s (%(BUILD_ID)s, %(LOCALE)s, %(PLATFORM)s) [%(BRANCH)s]' % log_data)
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
182
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
183 # ... and store to disk
184 basename = '%(BUILD_ID)s_%(PRODUCT)s_%(LOCALE)s_%(PLATFORM)s_%(KEY)s.log' % log_data
185 filename = os.path.join(self.log_folder, data['tree'], basename)
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
186
acd1a42 @whimboo Only log pulse notifications for triggered tests or in debug mode
whimboo authored
187 try:
188 JSONFile(filename).write(data)
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
189 except Exception, e:
190 self.logger.warning("Log file could not be written: %s." % str(e))
c454f63 @whimboo Exit early for heatbeat messages
whimboo authored
191
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
192 # if `--display-only` option has been specified only print build information and return
193 if self.display_only:
8e4346a @whimboo Only trigger jobs for valid builds. Fixes issue #7
whimboo authored
194 self.logger.info("Build properties:")
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
195 for prop in data:
196 self.logger.info("%20s:\t%s" % (prop, data[prop]))
81c4985 @whimboo In debug mode save everything but only log wanted builds
whimboo authored
197 return
198
869860b @whimboo Finally fix the code so we do not test failed builds
whimboo authored
199 # If the build process was broken we don't have to test this build
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
200 if data['status'] != 0:
201 self.logger.info('Cancel processing of broken build: status=%s' % results[data['status']])
869860b @whimboo Finally fix the code so we do not test failed builds
whimboo authored
202 return
203
ffc3688 @whimboo Run daily tests for holly branch (#365)
whimboo authored
204 # If it is not an official nightly or release branch, assume a project
205 # branch based off from mozilla-central
ed4b1cb @whimboo Pulse triggered release tests are broken due to project branch featur…
whimboo authored
206 if not 'mozilla-' in data['tree']:
c5a84a3 @whimboo Allow project branches to be run in Mozmill-CI jobs (#337)
whimboo authored
207 data['branch'] = data['tree']
208 data['tree'] = 'project'
209
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
210 # Queue up jobs for the branch as given by config settings
c6f513a @whimboo Stop testruns for esr31 nightly builds on production (#553)
whimboo authored
211 target_branch = self.config['testrun']['by_branch'].get(data['tree'])
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
212 target_platform = self.get_platform_identifier(data['platform'])
0365a7f @whimboo Add platform coverage per branch. Fixes issue #2
whimboo authored
213
c6f513a @whimboo Stop testruns for esr31 nightly builds on production (#553)
whimboo authored
214 # Ensure that the branch is really supported by us
215 if target_branch is None:
216 self.logger.error('Cancel processing of unsupported branch: %s' % data['tree'])
217 return
218
cb5f108 @whimboo Fix handling of locales for l10n tests (#534)
whimboo authored
219 # Handle blacklist items if present
b5be34d @andreeamatei Add blacklist for locales (#309)
andreeamatei authored
220 if 'blacklist' in target_branch:
cb5f108 @whimboo Fix handling of locales for l10n tests (#534)
whimboo authored
221 # Cancel processing of the build if the locale is blacklisted
b5be34d @andreeamatei Add blacklist for locales (#309)
andreeamatei authored
222 if 'locales' in target_branch['blacklist'] and \
223 data['locale'] in target_branch['blacklist']['locales']:
224 self.logger.info('Cancel processing of blacklisted locale: %s' % data['locale'])
225 return
226
cb5f108 @whimboo Fix handling of locales for l10n tests (#534)
whimboo authored
227 # Cancel processing of the build if the locale is not white-listed. An
228 # empty array means all locales will be processed.
229 if 'locales' in target_branch and len(target_branch['locales']) and \
b2acfab @whimboo Do not run tests for localized builds on mozilla-central (#220)
whimboo authored
230 data['locale'] not in target_branch['locales']:
b5be34d @andreeamatei Add blacklist for locales (#309)
andreeamatei authored
231 self.logger.info('Cancel processing of non-whitelisted locale: %s' % data['locale'])
b2acfab @whimboo Do not run tests for localized builds on mozilla-central (#220)
whimboo authored
232 return
233
0365a7f @whimboo Add platform coverage per branch. Fixes issue #2
whimboo authored
234 for testrun in target_branch['testruns']:
a1c112d @whimboo Don't run update tests if 'previous_buildid' is None (#130)
whimboo authored
235 # TODO: The following lines are pretty bad hacks,
236 # so make those configurable in the json config (#209)
cb7ace5 @whimboo Hardcoded fix to run endurance tests for en-US only (#209)
whimboo authored
237 # Do not run endurance tests for localized versions of Firefox
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
238 if testrun in ['endurance'] and data['locale'] != 'en-US':
cb7ace5 @whimboo Hardcoded fix to run endurance tests for en-US only (#209)
whimboo authored
239 continue
881da1a @whimboo Do not run update tests for localized daily builds (#238)
whimboo authored
240
241 # Do not run update tests for localized builds of Firefox, because
242 # packaging is broken if nighlies get retriggered
243 # See: https://bugzilla.mozilla.org/show_bug.cgi?id=858953
244 if testrun in ['update'] and data['locale'] != 'en-US':
245 continue
246
a1c112d @whimboo Don't run update tests if 'previous_buildid' is None (#130)
whimboo authored
247 # Do not run update tests if no previous build id is specified
248 # See: https://bugzilla.mozilla.org/show_bug.cgi?id=714806#c17
249 if testrun in ['update'] and not data['previous_buildid']:
250 continue
cb7ace5 @whimboo Hardcoded fix to run endurance tests for en-US only (#209)
whimboo authored
251
0365a7f @whimboo Add platform coverage per branch. Fixes issue #2
whimboo authored
252 # Fire off a build for each supported platform
253 for node in target_branch['platforms'][target_platform]:
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
254 job = '%s_%s' % (data['tree'], testrun)
0365a7f @whimboo Add platform coverage per branch. Fixes issue #2
whimboo authored
255 parameters = self.generate_job_parameters(testrun, node,
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
256 target_platform, data)
257
258 self.logger.info('Triggering job "%s" on "%s"' % (job, node))
259 try:
260 self.jenkins.build_job(job, parameters)
261 except Exception, e:
262 # For now simply discard and continue.
263 # Later we might want to implement a queuing mechanism.
264 self.logger.error('Jenkins instance at "%s" cannot be reached: %s' % (
265 self.config['jenkins']['url'],
266 str(e)))
267
8c24448 @whimboo Slow down Jenkins API calls when creating ondemand jobs (#364)
whimboo authored
268 # Give Jenkins a bit of breath to process other threads
269 time.sleep(2.5)
270
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
271 def on_debug(self, data):
272 """In debug mode save off all raw notifications"""
273
274 basename = '%(BUILD_ID)s_%(PRODUCT)s_%(LOCALE)s_%(PLATFORM)s_%(KEY)s.log' % {
275 'BUILD_ID': data['payload']['buildid'],
276 'PRODUCT': data['payload']['product'],
277 'LOCALE': data['payload']['locale'],
278 'PLATFORM': data['payload']['platform'],
279 'KEY': data['payload']['key']}
280 filename = os.path.join('debug', data['payload']['tree'], basename)
281
282 try:
283 JSONFile(filename).write(data)
284 except Exception, e:
285 self.logger.warning("Debug file could not be written: %s." % str(e))
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
286
287
288 class DailyAutomation(Automation):
289
290 def __init__(self, *args, **kwargs):
291 Automation.__init__(self, *args, **kwargs)
9ee67a0 @whimboo Create separate config files for daily and l10n tests
whimboo authored
292
b46ca07 @whimboo Add debug possibilities
whimboo authored
293
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
294 def main():
b46ca07 @whimboo Add debug possibilities
whimboo authored
295 parser = optparse.OptionParser()
f0dcc05 @whimboo Allow to manually push logged Pulse messages
whimboo authored
296 parser.add_option('--debug',
b46ca07 @whimboo Add debug possibilities
whimboo authored
297 dest='debug',
f0dcc05 @whimboo Allow to manually push logged Pulse messages
whimboo authored
298 action='store_true',
b46ca07 @whimboo Add debug possibilities
whimboo authored
299 default=False)
f0dcc05 @whimboo Allow to manually push logged Pulse messages
whimboo authored
300 parser.add_option('--log-folder',
301 dest='log_folder',
302 default='log',
303 help='Folder to write notification log files into')
2a54eed @whimboo Add support for Mozilla Pulse Guardian (#518)
whimboo authored
304 parser.add_option('--pulse-authfile',
305 dest='pulse_authfile',
306 default='.pulse_config.ini',
307 help='Path to the authentiation file for Pulse Guardian')
f0dcc05 @whimboo Allow to manually push logged Pulse messages
whimboo authored
308 parser.add_option('--push-message',
309 dest='message',
310 help='Log file of a Pulse message to process for Jenkins')
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
311 parser.add_option('--display-only',
312 dest='display_only',
54c1a18 @whimboo Add feature to show build properties out of the pulse notificiation
whimboo authored
313 action='store_true',
314 default=False,
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
315 help='Only display build properties and don\'t trigger jobs.')
b46ca07 @whimboo Add debug possibilities
whimboo authored
316 options, args = parser.parse_args()
317
9ee67a0 @whimboo Create separate config files for daily and l10n tests
whimboo authored
318 if not len(args):
319 parser.error('A configuration file has to be passed in as first argument.')
320
fa35ef6 @cosmin-malutan Add timestamp to pulse logger (#410)
cosmin-malutan authored
321 logging.Formatter.converter = time.gmtime
322 logging.basicConfig(level=logging.INFO,
323 format='%(asctime)s %(levelname)s:%(name)s:%(message)s',
324 datefmt='%Y-%m-%dT%H:%M:%SZ')
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
325 logger = logging.getLogger('automation')
326
2a54eed @whimboo Add support for Mozilla Pulse Guardian (#518)
whimboo authored
327 DailyAutomation(configfile=args[0],
328 pulse_authfile=options.pulse_authfile,
6ebddc2 @whimboo Allow testruns to be configured per branch. Fix #4
whimboo authored
329 debug=options.debug,
330 log_folder=options.log_folder,
331 logger=logger,
54c1a18 @whimboo Add feature to show build properties out of the pulse notificiation
whimboo authored
332 message=options.message,
b02a575 @whimboo Use pulsebuildmonitor to handle build notifications (#176)
whimboo authored
333 display_only=options.display_only)
3f395ca @whimboo Update platform map, add some Tier 1 locales, and update handling of …
whimboo authored
334
335 if __name__ == "__main__":
336 main()
Something went wrong with that request. Please try again.