blob: f089c656ba0e4c9ae34781036efc272a6a00673d [file] [log] [blame]
Oleh Prypin1a0593f2019-03-11 09:43:28 +01001#!/usr/bin/env lucicfg
2
3# Copyright (c) 2019 The WebRTC project authors. All rights reserved.
4# Use of this source code is governed by a BSD-style license that can be
5# found in the LICENSE file.
6
Christoffer Janssona814c562021-09-09 13:44:54 +02007# https://chromium.googlesource.com/infra/luci/luci-go/+/main/lucicfg/doc/
Oleh Prypin1a0593f2019-03-11 09:43:28 +01008
Jeremy Leconteea2016b2020-07-01 09:47:22 +02009"""LUCI project configuration for WebRTC CQ and CI."""
10
Vadim Shtayurac343a082022-02-09 12:59:42 -080011lucicfg.check_version("1.30.9")
Mirko Bonadei9189d9c2020-06-09 21:54:18 +020012
Oleh Prypin1a0593f2019-03-11 09:43:28 +010013WEBRTC_GIT = "https://webrtc.googlesource.com/src"
14WEBRTC_GERRIT = "https://webrtc-review.googlesource.com/src"
Mirko Bonadeif4b78bf2021-04-29 11:23:41 +020015WEBRTC_TROOPER_EMAIL = "webrtc-troopers-robots@google.com"
Jeremy Leconte39fbd002022-02-22 10:01:14 +010016WEBRTC_IOS_XCODE_VERSION = "12a7209"
Jeremy Lecontea9cd35e2022-02-22 15:15:21 +010017WEBRTC_XCODE13 = "13a233"
Jeremy Leconte228f54f2022-02-23 11:10:33 +010018DEFAULT_CPU = "x86-64"
Oleh Prypin1a0593f2019-03-11 09:43:28 +010019
Jeremy Leconte39fbd002022-02-22 10:01:14 +010020# Helpers:
21
Jeremy Leconte1efa6a12022-02-23 09:17:12 +010022def make_goma_properties(enable_ats = True, jobs = None):
Jeremy Leconte39fbd002022-02-22 10:01:14 +010023 """Makes a default goma property with the specified argument.
24
25 Args:
26 enable_ats: True if the ATS should be enabled.
27 jobs: Number of jobs to be used by the builder.
28 Returns:
29 A dictonary with the goma properties.
30 """
31 goma_properties = {
Mirko Bonadei1e905342020-03-04 09:39:42 +010032 "server_host": "goma.chromium.org",
Jeremy Leconteea2016b2020-07-01 09:47:22 +020033 "use_luci_auth": True,
Jeremy Leconte39fbd002022-02-22 10:01:14 +010034 }
Jeremy Leconte1efa6a12022-02-23 09:17:12 +010035 if not enable_ats:
Jeremy Leconte39fbd002022-02-22 10:01:14 +010036 goma_properties["enable_ats"] = enable_ats
37 if jobs:
38 goma_properties["jobs"] = jobs
39 return {"$build/goma": goma_properties}
Mirko Bonadei5aafd472021-04-21 10:42:00 +020040
Artem Titov70d45af2021-10-11 13:25:18 +020041# Add names of builders to remove from LKGR finder to this list. This is
42# useful when a failure can be safely ignored while fixing it without
43# blocking the LKGR finder on it.
44skipped_lkgr_bots = [
Artem Titov70d45af2021-10-11 13:25:18 +020045]
46
Vadim Shtayurac343a082022-02-09 12:59:42 -080047# Use LUCI Scheduler BBv2 names and add Scheduler realms configs.
48lucicfg.enable_experiment("crbug.com/1182002")
49
Christoffer Jansson3e21f3f2021-11-17 16:30:51 +010050luci.builder.defaults.experiments.set(
51 {
Christoffer Jansson3e21f3f2021-11-17 16:30:51 +010052 "luci.recipes.use_python3": 100,
53 },
54)
Jeremy Leconte34db3992021-11-23 09:44:31 +010055luci.builder.defaults.test_presentation.set(
56 resultdb.test_presentation(grouping_keys = ["status", "v.test_suite"]),
57)
Andrii Shyshkalov20b21872021-04-28 15:10:53 +020058
Oleh Prypin1a0593f2019-03-11 09:43:28 +010059lucicfg.config(
60 config_dir = ".",
61 tracked_files = [
62 "commit-queue.cfg",
63 "cr-buildbucket.cfg",
64 "luci-logdog.cfg",
65 "luci-milo.cfg",
Oleh Prypin71d17422019-03-28 08:43:16 +010066 "luci-notify.cfg",
Oleh Prypin705b6a62019-04-03 23:10:51 +020067 "luci-notify/**/*",
Oleh Prypin1a0593f2019-03-11 09:43:28 +010068 "luci-scheduler.cfg",
69 "project.cfg",
Andrii Shyshkalov0efa6da2021-04-26 20:40:33 +020070 "realms.cfg",
Oleh Prypin1a0593f2019-03-11 09:43:28 +010071 ],
Jeremy Leconteea2016b2020-07-01 09:47:22 +020072 lint_checks = ["default"],
Oleh Prypin1a0593f2019-03-11 09:43:28 +010073)
74
75luci.project(
76 name = "webrtc",
77 buildbucket = "cr-buildbucket.appspot.com",
78 logdog = "luci-logdog.appspot.com",
79 milo = "luci-milo.appspot.com",
Oleh Prypin71d17422019-03-28 08:43:16 +010080 notify = "luci-notify.appspot.com",
Oleh Prypin1a0593f2019-03-11 09:43:28 +010081 scheduler = "luci-scheduler.appspot.com",
82 swarming = "chromium-swarm.appspot.com",
83 acls = [
84 acl.entry(
85 [acl.BUILDBUCKET_READER, acl.LOGDOG_READER, acl.PROJECT_CONFIGS_READER, acl.SCHEDULER_READER],
86 groups = ["all"],
87 ),
88 acl.entry(acl.LOGDOG_WRITER, groups = ["luci-logdog-chromium-writers"]),
89 acl.entry(acl.SCHEDULER_OWNER, groups = ["project-webrtc-admins"]),
90 ],
Andrii Shyshkalov0efa6da2021-04-26 20:40:33 +020091 bindings = [
92 luci.binding(
Vadim Shtayura64ca5e62021-11-11 17:10:18 -080093 roles = "role/configs.validator",
94 users = [
95 "webrtc-try-builder@chops-service-accounts.iam.gserviceaccount.com",
96 ],
97 ),
98 luci.binding(
Andrii Shyshkalov0efa6da2021-04-26 20:40:33 +020099 roles = "role/swarming.poolOwner",
100 groups = "project-webrtc-admins",
101 ),
102 luci.binding(
103 roles = "role/swarming.poolViewer",
104 groups = "all",
105 ),
Andrii Shyshkalov2961b642021-04-29 14:01:53 +0200106 # Allow any WebRTC build to trigger a test ran under chromium-tester@
107 # task service account.
108 luci.binding(
109 roles = "role/swarming.taskServiceAccount",
110 users = [
111 "chromium-tester@chops-service-accounts.iam.gserviceaccount.com",
112 ],
113 ),
Andrii Shyshkalov0efa6da2021-04-26 20:40:33 +0200114 ],
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100115)
116
117luci.logdog(
118 gs_bucket = "chromium-luci-logdog",
119)
120
121luci.milo(
122 logo = "https://storage.googleapis.com/chrome-infra/webrtc-logo-vert-retro-255x305.png",
123)
124
Owen Rodleya55c38e2020-06-15 11:16:10 +1000125luci.notify(tree_closing_enabled = True)
126
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100127luci.cq(
128 status_host = "chromium-cq-status.appspot.com",
129 submit_max_burst = 1,
130 submit_burst_delay = 1 * time.minute,
131)
132
133luci.gitiles_poller(
Christoffer Janssonfa646892021-06-28 17:34:20 +0200134 name = "webrtc-gitiles-trigger-main",
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100135 bucket = "ci",
136 repo = WEBRTC_GIT,
Christoffer Janssonfa646892021-06-28 17:34:20 +0200137 refs = ["refs/heads/main"],
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100138)
139
Andrii Shyshkalov0efa6da2021-04-26 20:40:33 +0200140# Swarming permissions:
141
Andrii Shyshkalovc26aaad2021-04-27 16:47:26 +0200142luci.realm(name = "pools/cron", bindings = [
143 # Unlike WebRTC's own builders, other projects need an explicit grant to use this pool.
144 luci.binding(
145 roles = "role/swarming.poolUser",
146 projects = "libyuv",
147 ),
148])
149
Andrii Shyshkalov0efa6da2021-04-26 20:40:33 +0200150luci.realm(name = "pools/ci")
Andrii Shyshkalovc26aaad2021-04-27 16:47:26 +0200151luci.realm(name = "pools/ci-tests", bindings = [
152 # Allow task service accounts of .ci pool/bucket to trigger tasks here.
153 luci.binding(
154 roles = "role/swarming.poolUser",
155 groups = "project-webrtc-ci-task-accounts",
156 ),
157 # Allow tasks here to use .ci task service accounts.
158 luci.binding(
159 roles = "role/swarming.taskServiceAccount",
160 groups = "project-webrtc-ci-task-accounts",
161 ),
162])
Jeremy Leconte053e63c2021-11-24 13:55:48 +0100163luci.realm(name = "ci", bindings = [
164 # Allow CI builders to create invocations in their own builds.
165 luci.binding(
166 roles = "role/resultdb.invocationCreator",
167 groups = "project-webrtc-ci-task-accounts",
168 ),
169])
Andrii Shyshkalovc26aaad2021-04-27 16:47:26 +0200170
Jeremy Leconte053e63c2021-11-24 13:55:48 +0100171luci.realm(name = "pools/try", bindings = [
172 # Allow to use LED & Swarming "Debug" feature to a larger group but only on try bots / builders.
173 luci.binding(
174 roles = "role/swarming.poolUser",
175 groups = "project-webrtc-led-users",
176 ),
177])
Andrii Shyshkalovc26aaad2021-04-27 16:47:26 +0200178luci.realm(name = "pools/try-tests", bindings = [
179 # Allow task service accounts of .try pool/bucket to trigger tasks here.
180 luci.binding(
181 roles = "role/swarming.poolUser",
182 groups = "project-webrtc-try-task-accounts",
183 ),
184 # Allow tasks here to use .try task service accounts.
185 luci.binding(
186 roles = "role/swarming.taskServiceAccount",
187 groups = "project-webrtc-try-task-accounts",
188 ),
189])
Jeremy Leconte053e63c2021-11-24 13:55:48 +0100190luci.realm(name = "try", bindings = [
191 luci.binding(
192 roles = "role/swarming.taskTriggerer",
193 groups = "project-webrtc-led-users",
194 ),
195 # Allow try builders to create invocations in their own builds.
196 luci.binding(
197 roles = "role/resultdb.invocationCreator",
198 groups = "project-webrtc-try-task-accounts",
199 ),
200])
Andrii Shyshkalov0efa6da2021-04-26 20:40:33 +0200201
Mirko Bonadei4cf0fc72021-08-31 17:38:10 +0200202luci.realm(name = "pools/perf", bindings = [
Jeremy Leconte053e63c2021-11-24 13:55:48 +0100203 # Allow to use LED & Swarming "Debug" feature to a larger group but only on perf bots / builders.
Mirko Bonadei4cf0fc72021-08-31 17:38:10 +0200204 luci.binding(
205 roles = "role/swarming.poolUser",
206 groups = "project-webrtc-led-users",
207 ),
208])
Jeremy Leconte053e63c2021-11-24 13:55:48 +0100209luci.realm(name = "perf", bindings = [
210 luci.binding(
211 roles = "role/swarming.taskTriggerer",
212 groups = "project-webrtc-led-users",
213 ),
214])
Mirko Bonadei4cf0fc72021-08-31 17:38:10 +0200215
Jeremy Leconte053e63c2021-11-24 13:55:48 +0100216luci.realm(name = "@root", bindings = [
217 # Allow admins to use LED & Swarming "Debug" feature on all WebRTC bots.
218 luci.binding(
219 roles = "role/swarming.poolUser",
220 groups = "project-webrtc-admins",
221 ),
222 luci.binding(
223 roles = "role/swarming.taskTriggerer",
224 groups = "project-webrtc-admins",
225 ),
226])
Andrii Shyshkalov0efa6da2021-04-26 20:40:33 +0200227
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100228# Bucket definitions:
229
230luci.bucket(
231 name = "try",
232 acls = [
233 acl.entry(acl.BUILDBUCKET_TRIGGERER, groups = [
234 "service-account-cq",
235 "project-webrtc-tryjob-access",
236 ]),
237 ],
238)
239
240luci.bucket(
241 name = "ci",
242 acls = [
Oleh Prypinf35939d2019-05-03 20:42:38 +0200243 acl.entry(acl.BUILDBUCKET_TRIGGERER, groups = [
244 "project-webrtc-ci-schedulers",
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100245 ]),
Jeremy Leconte2e25bb52020-07-16 09:38:56 +0200246 acl.entry(acl.BUILDBUCKET_TRIGGERER, groups = [
247 # Allow Pinpoint to trigger builds for bisection
248 "service-account-chromeperf",
249 ]),
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100250 ],
251)
252
253luci.bucket(
254 name = "perf",
255 acls = [
256 acl.entry(acl.BUILDBUCKET_TRIGGERER, users = [
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100257 "webrtc-ci-builder@chops-service-accounts.iam.gserviceaccount.com",
258 ]),
259 ],
260)
261
262luci.bucket(
263 name = "cron",
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100264)
265
266# Commit queue definitions:
267
268luci.cq_group(
269 name = "cq",
270 tree_status_host = "webrtc-status.appspot.com",
Christoffer Jansson1746b252021-05-31 16:03:55 +0200271 watch = [cq.refset(repo = WEBRTC_GERRIT, refs = ["refs/heads/master", "refs/heads/main"])],
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100272 acls = [
273 acl.entry(acl.CQ_COMMITTER, groups = ["project-webrtc-committers"]),
274 acl.entry(acl.CQ_DRY_RUNNER, groups = ["project-webrtc-tryjob-access"]),
275 ],
276 retry_config = cq.RETRY_ALL_FAILURES,
Oleh Prypin5416f2d2019-08-02 09:43:15 +0200277 cancel_stale_tryjobs = True,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100278)
279
280luci.cq_group(
Oleh Prypin7d1cabe2019-03-14 15:10:30 +0100281 name = "cq_branch",
282 watch = [cq.refset(repo = WEBRTC_GERRIT, refs = ["refs/branch-heads/.+"])],
283 acls = [
284 acl.entry(acl.CQ_COMMITTER, groups = ["project-webrtc-committers"]),
285 acl.entry(acl.CQ_DRY_RUNNER, groups = ["project-webrtc-tryjob-access"]),
286 ],
287 retry_config = cq.RETRY_ALL_FAILURES,
Oleh Prypin5416f2d2019-08-02 09:43:15 +0200288 cancel_stale_tryjobs = True,
Oleh Prypin7d1cabe2019-03-14 15:10:30 +0100289)
290
291luci.cq_group(
292 name = "cq_infra",
293 watch = [cq.refset(repo = WEBRTC_GERRIT, refs = ["refs/heads/infra/config"])],
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100294 acls = [
295 acl.entry(acl.CQ_COMMITTER, groups = ["project-webrtc-admins"]),
296 acl.entry(acl.CQ_DRY_RUNNER, groups = ["project-webrtc-tryjob-access"]),
297 ],
298 retry_config = cq.RETRY_ALL_FAILURES,
Oleh Prypin5416f2d2019-08-02 09:43:15 +0200299 cancel_stale_tryjobs = True,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100300)
301
302luci.cq_tryjob_verifier(
303 builder = "presubmit",
Oleh Prypin7d1cabe2019-03-14 15:10:30 +0100304 cq_group = "cq_infra",
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100305)
306
Oleh Prypine56cd9b2019-05-29 21:14:31 +0200307luci.cq_tryjob_verifier(
308 builder = "webrtc-internal:g3.webrtc-internal.try/internal_compile_lite",
309 owner_whitelist = ["project-webrtc-internal-tryjob-access"],
310 cq_group = "cq",
311)
312
Oleh Prypin71d17422019-03-28 08:43:16 +0100313# Notifier definitions:
314
315luci.notifier(
Mirko Bonadei875a27a2020-07-11 15:04:58 +0200316 name = "post_submit_failure_notifier",
317 on_new_status = ["FAILURE"],
Mirko Bonadeif4b78bf2021-04-29 11:23:41 +0200318 notify_emails = [WEBRTC_TROOPER_EMAIL],
Christoffer Jansson16635012021-10-25 16:32:38 +0200319 notify_blamelist = True,
Oleh Prypin705b6a62019-04-03 23:10:51 +0200320 template = luci.notifier_template(
Mirko Bonadei875a27a2020-07-11 15:04:58 +0200321 name = "build_failure",
322 body = io.read_file("luci-notify/email-templates/build_failure.template"),
Oleh Prypin705b6a62019-04-03 23:10:51 +0200323 ),
Oleh Prypin71d17422019-03-28 08:43:16 +0100324)
325
326luci.notifier(
327 name = "cron_notifier",
Jeremy Leconte67a904e2020-07-08 11:48:18 +0200328 on_new_status = ["FAILURE", "INFRA_FAILURE"],
Mirko Bonadeif4b78bf2021-04-29 11:23:41 +0200329 notify_emails = [WEBRTC_TROOPER_EMAIL],
Oleh Prypin705b6a62019-04-03 23:10:51 +0200330 template = luci.notifier_template(
331 name = "cron",
332 body = io.read_file("luci-notify/email-templates/cron.template"),
333 ),
Oleh Prypin71d17422019-03-28 08:43:16 +0100334)
335
Jeremy Leconte67a904e2020-07-08 11:48:18 +0200336luci.notifier(
Mirko Bonadei875a27a2020-07-11 15:04:58 +0200337 name = "infra_failure_notifier",
Jeremy Leconte67a904e2020-07-08 11:48:18 +0200338 on_new_status = ["INFRA_FAILURE"],
Mirko Bonadeif4b78bf2021-04-29 11:23:41 +0200339 notify_emails = [WEBRTC_TROOPER_EMAIL],
Jeremy Leconte67a904e2020-07-08 11:48:18 +0200340 template = luci.notifier_template(
Mirko Bonadei875a27a2020-07-11 15:04:58 +0200341 name = "infra_failure",
342 body = io.read_file("luci-notify/email-templates/infra_failure.template"),
Jeremy Leconte67a904e2020-07-08 11:48:18 +0200343 ),
344)
345
Owen Rodley6b721ba2020-05-26 10:04:20 +1000346# Tree closer definitions:
347
348luci.tree_closer(
349 name = "webrtc_tree_closer",
350 tree_status_host = "webrtc-status.appspot.com",
Owen Rodley6b721ba2020-05-26 10:04:20 +1000351 # TODO: These step filters are copied verbatim from Gatekeeper, for testing
352 # that LUCI-Notify would take the exact same actions. Once we've switched
353 # over, this should be updated - several of these steps don't exist in
354 # WebRTC recipes.
355 failed_step_regexp = [
356 "bot_update",
357 "compile",
358 "gclient runhooks",
359 "runhooks",
360 "update",
361 "extract build",
362 "cleanup_temp",
363 "taskkill",
364 "compile",
365 "gn",
366 ],
367 failed_step_regexp_exclude = ".*\\(experimental\\).*",
368)
369
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100370# Recipe definitions:
371
372def recipe(recipe, pkg = "infra/recipe_bundles/chromium.googlesource.com/chromium/tools/build"):
373 return luci.recipe(
374 name = recipe.split("/")[-1],
375 cipd_package = pkg,
Christoffer Janssona814c562021-09-09 13:44:54 +0200376 cipd_version = "refs/heads/main",
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100377 recipe = recipe,
Christoffer Jansson659d9322021-11-18 15:56:00 +0100378 use_python3 = True,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100379 )
380
381recipe("chromium_trybot")
382recipe("run_presubmit")
383recipe("webrtc/auto_roll_webrtc_deps")
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100384recipe("webrtc/ios_api_framework")
385recipe("webrtc/libfuzzer")
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100386recipe("webrtc/standalone")
Mirko Bonadei54bbd1c2020-12-14 15:54:46 +0100387recipe("webrtc/update_webrtc_binary_version")
Jeff Yoonf421c682020-12-17 00:16:22 -0800388recipe("lkgr_finder", pkg = "infra/recipe_bundles/chromium.googlesource.com/chromium/tools/build")
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100389
390# Console definitions:
391
Josip Sokcevic5a906ed2021-06-28 08:55:46 -0700392luci.console_view(name = "ci", title = "Main", repo = WEBRTC_GIT, header = "console-header.textpb", refs = ["refs/heads/master", "refs/heads/main"])
393luci.console_view(name = "perf", title = "Perf", repo = WEBRTC_GIT, header = "console-header.textpb", refs = ["refs/heads/master", "refs/heads/main"])
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100394luci.list_view(name = "cron", title = "Cron")
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100395luci.list_view(name = "try", title = "Tryserver")
396
397def add_milo(builder, views):
398 """Add Milo console entries for the builder.
399
400 Args:
401 builder: builder name (str).
402 views: dict where keys are names of consoles and values are either a
403 category for the console (str, pipe-separated) or True, which means
404 adding to a list view rather than a console.
405 """
406 for view_name, category in views.items():
407 if category == None:
408 continue
409 elif type(category) == "string":
410 category, _, short_name = category.rpartition("|")
411 luci.console_view_entry(
412 console_view = view_name,
413 builder = builder,
414 category = category or None,
415 short_name = short_name or None,
416 )
417 elif category == True:
418 luci.list_view_entry(
419 list_view = view_name,
420 builder = builder,
421 )
422 else:
423 fail("Unexpected value for category: %r" % category)
424
Jeremy Leconteec86a692022-02-28 09:09:52 +0100425lkgr_builders = []
Oleh Prypin8f0dc312019-05-31 15:54:35 +0200426
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100427# Builder-defining functions:
428
Artem Titarenkof6588b72019-11-14 14:28:11 +0100429def webrtc_builder(
430 name,
Jeremy Lecontec2516202021-12-14 13:01:24 +0100431 bucket,
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100432 dimensions,
433 properties = None,
Artem Titarenkof6588b72019-11-14 14:28:11 +0100434 recipe = "standalone",
Artem Titarenkof6588b72019-11-14 14:28:11 +0100435 priority = 30,
436 execution_timeout = 2 * time.hour,
437 **kwargs):
Mirko Bonadeib7ef4602020-07-01 13:28:26 +0200438 """WebRTC specific wrapper around luci.builder.
439
440 Args:
441 name: builder name (str).
Jeremy Lecontec2516202021-12-14 13:01:24 +0100442 bucket: The name of the bucket the builder belongs to.
Mirko Bonadeib7ef4602020-07-01 13:28:26 +0200443 dimensions: dict of Swarming dimensions (strings) to search machines by.
444 properties: dict of properties to pass to the recipe (on top of the default ones).
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100445 recipe: string with the name of the recipe to run.
Mirko Bonadeib7ef4602020-07-01 13:28:26 +0200446 priority: int [1-255] or None, indicating swarming task priority, lower is
447 more important. If None, defer the decision to Buildbucket service.
448 execution_timeout: int or None, how long to wait for a running build to finish before
449 forcefully aborting it and marking the build as timed out. If None,
450 defer the decision to Buildbucket service.
Mirko Bonadeib7ef4602020-07-01 13:28:26 +0200451 **kwargs: Pass on to webrtc_builder / luci.builder.
452 Returns:
453 A luci.builder.
454 """
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100455 properties = properties or {}
456 properties["$recipe_engine/isolated"] = {
457 "server": "https://isolateserver.appspot.com",
458 }
Jeremy Lecontec2516202021-12-14 13:01:24 +0100459 resultdb_bq_table = "webrtc-ci.resultdb." + bucket + "_test_results"
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100460 return luci.builder(
461 name = name,
Jeremy Lecontec2516202021-12-14 13:01:24 +0100462 bucket = bucket,
Oleh Prypin705b6a62019-04-03 23:10:51 +0200463 executable = recipe,
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100464 dimensions = dimensions,
Mirko Bonadeib7ef4602020-07-01 13:28:26 +0200465 properties = properties,
Artem Titarenkof6588b72019-11-14 14:28:11 +0100466 execution_timeout = execution_timeout,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100467 priority = priority,
468 build_numbers = True,
469 swarming_tags = ["vpython:native-python-wrapper"],
Jeremy Lecontec2516202021-12-14 13:01:24 +0100470 resultdb_settings = resultdb.settings(
471 enable = True,
472 bq_exports = [
473 resultdb.export_test_results(bq_table = resultdb_bq_table),
474 ],
475 ),
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100476 **kwargs
477 )
478
479def ci_builder(
480 name,
481 ci_cat,
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100482 dimensions,
483 properties = None,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100484 perf_cat = None,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100485 prioritized = False,
Oleh Prypinf5432c52019-03-19 15:10:37 +0100486 enabled = True,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100487 **kwargs):
Oleh Prypine5677672019-04-25 12:21:35 +0200488 """Add a post-submit builder.
489
490 Args:
491 name: builder name (str).
492 ci_cat: the category + name for the /ci/ console, or None to omit from the console.
Oleh Prypine5677672019-04-25 12:21:35 +0200493 dimensions: dict of Swarming dimensions (strings) to search machines by.
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100494 properties: dict of properties to pass to the recipe (on top of the default ones).
495 perf_cat: the category + name for the /perf/ console, or None to omit from the console.
Oleh Prypine5677672019-04-25 12:21:35 +0200496 prioritized: True to make this builder have a higher priority and never batch builds.
497 enabled: False to exclude this builder from consoles and failure notifications.
498 **kwargs: Pass on to webrtc_builder / luci.builder.
499 Returns:
500 A luci.builder.
501
502 Notifications are also disabled if a builder is not on either of /ci/ or /perf/ consoles.
503 """
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100504 if prioritized:
505 kwargs["triggering_policy"] = scheduler.greedy_batching(
506 max_batch_size = 1,
507 max_concurrent_invocations = 3,
508 )
509 kwargs["priority"] = 29
510
Oleh Prypinf5432c52019-03-19 15:10:37 +0100511 if enabled:
Jeremy Leconte39fbd002022-02-22 10:01:14 +0100512 add_milo(name, {"ci": ci_cat, "perf": perf_cat})
Oleh Prypin8f0dc312019-05-31 15:54:35 +0200513 if ci_cat:
Jeremy Leconteec86a692022-02-28 09:09:52 +0100514 lkgr_builders.append(name)
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100515 dimensions.update({"pool": "luci.webrtc.ci", "cpu": kwargs.pop("cpu", DEFAULT_CPU)})
516 properties = properties or {}
517 properties["builder_group"] = "client.webrtc"
518 properties.update(make_goma_properties())
Jeremy Leconteec86a692022-02-28 09:09:52 +0100519 notifies = ["post_submit_failure_notifier", "infra_failure_notifier"]
520 notifies += ["webrtc_tree_closer"] if name not in skipped_lkgr_bots else []
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100521 return webrtc_builder(
522 name = name,
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100523 dimensions = dimensions,
524 properties = properties,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100525 bucket = "ci",
526 service_account = "webrtc-ci-builder@chops-service-accounts.iam.gserviceaccount.com",
Christoffer Janssonfa646892021-06-28 17:34:20 +0200527 triggered_by = ["webrtc-gitiles-trigger-main"] if enabled else None,
Oleh Prypin71d17422019-03-28 08:43:16 +0100528 repo = WEBRTC_GIT,
Jeremy Leconteec86a692022-02-28 09:09:52 +0100529 notifies = notifies if enabled else None,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100530 **kwargs
531 )
532
533def try_builder(
534 name,
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100535 dimensions,
536 properties = None,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100537 try_cat = True,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100538 cq = {},
Oleh Prypin7d1cabe2019-03-14 15:10:30 +0100539 branch_cq = True,
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100540 goma_enable_ats = True,
541 goma_jobs = None,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100542 **kwargs):
Oleh Prypine5677672019-04-25 12:21:35 +0200543 """Add a pre-submit builder.
544
545 Args:
546 name: builder name (str).
Oleh Prypine5677672019-04-25 12:21:35 +0200547 dimensions: dict of Swarming dimensions (strings) to search machines by.
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100548 properties: dict of properties to pass to the recipe (on top of the default ones).
549 try_cat: boolean, whether to include this builder in the /try/ console. See also: `add_milo`.
Oleh Prypine5677672019-04-25 12:21:35 +0200550 cq: None to exclude this from all commit queues, or a dict of kwargs for cq_tryjob_verifier.
Oleh Prypin7d1cabe2019-03-14 15:10:30 +0100551 branch_cq: False to exclude this builder just from the release-branch CQ.
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100552 goma_enable_ats: True if the ATS should be enabled by the builder.
553 goma_jobs: Number of jobs to be used by the builder.
Oleh Prypine5677672019-04-25 12:21:35 +0200554 **kwargs: Pass on to webrtc_builder / luci.builder.
555 Returns:
556 A luci.builder.
557 """
Jeremy Leconte39fbd002022-02-22 10:01:14 +0100558 add_milo(name, {"try": try_cat})
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100559 dimensions.update({"pool": "luci.webrtc.try", "cpu": DEFAULT_CPU})
560 properties = properties or {}
561 properties["builder_group"] = "tryserver.webrtc"
562 properties.update(make_goma_properties(enable_ats = goma_enable_ats, jobs = goma_jobs))
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100563 if cq != None:
Jeremy Leconte39fbd002022-02-22 10:01:14 +0100564 luci.cq_tryjob_verifier(name, cq_group = "cq", **cq)
Oleh Prypin7d1cabe2019-03-14 15:10:30 +0100565 if branch_cq:
Jeremy Leconte39fbd002022-02-22 10:01:14 +0100566 luci.cq_tryjob_verifier(name, cq_group = "cq_branch", **cq)
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100567
568 return webrtc_builder(
569 name = name,
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100570 dimensions = dimensions,
571 properties = properties,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100572 bucket = "try",
573 service_account = "webrtc-try-builder@chops-service-accounts.iam.gserviceaccount.com",
Mirko Bonadei875a27a2020-07-11 15:04:58 +0200574 notifies = ["infra_failure_notifier"],
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100575 **kwargs
576 )
577
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100578def perf_builder(name, perf_cat, **kwargs):
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100579 add_milo(name, {"perf": perf_cat})
Jeremy Leconte1efa6a12022-02-23 09:17:12 +0100580 properties = make_goma_properties()
Jeremy Leconte39fbd002022-02-22 10:01:14 +0100581 properties["builder_group"] = "client.webrtc.perf"
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100582 return webrtc_builder(
583 name = name,
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100584 dimensions = {"pool": "luci.webrtc.perf", "os": "Linux"},
Jeremy Leconte39fbd002022-02-22 10:01:14 +0100585 properties = properties,
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100586 bucket = "perf",
587 service_account = "webrtc-ci-builder@chops-service-accounts.iam.gserviceaccount.com",
588 # log_base of 1.7 means:
589 # when there are P pending builds, LUCI will batch the first B builds.
590 # P: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 ...
591 # B: 1 1 2 2 3 3 3 3 4 4 4 4 4 4 5 ...
Jeremy Leconteea2016b2020-07-01 09:47:22 +0200592 triggering_policy = scheduler.logarithmic_batching(log_base = 1.7),
Christoffer Jansson16635012021-10-25 16:32:38 +0200593 repo = WEBRTC_GIT,
Artem Titarenkof6588b72019-11-14 14:28:11 +0100594 execution_timeout = 3 * time.hour,
Mirko Bonadei875a27a2020-07-11 15:04:58 +0200595 notifies = ["post_submit_failure_notifier", "infra_failure_notifier"],
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100596 **kwargs
597 )
598
Jeremy Leconte39fbd002022-02-22 10:01:14 +0100599def cron_builder(name, service_account = None, **kwargs):
Mirko Bonadei54bbd1c2020-12-14 15:54:46 +0100600 if service_account == None:
601 service_account = "chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com"
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100602 add_milo(name, {"cron": True})
603 return webrtc_builder(
604 name = name,
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100605 dimensions = {"pool": "luci.webrtc.cron", "os": "Linux", "cpu": DEFAULT_CPU},
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100606 bucket = "cron",
Mirko Bonadei54bbd1c2020-12-14 15:54:46 +0100607 service_account = service_account,
Oleh Prypin71d17422019-03-28 08:43:16 +0100608 notifies = ["cron_notifier"],
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100609 **kwargs
610 )
611
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100612def normal_builder_factory(**common_kwargs):
613 def builder(*args, **kwargs):
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100614 kwargs.update(common_kwargs)
615 return ci_builder(*args, **kwargs)
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100616
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100617 def try_job(name, **kwargs):
618 kwargs.update(common_kwargs)
619 return try_builder(name, **kwargs)
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100620
621 return builder, try_job
622
623# Mixins:
624
625linux_builder, linux_try_job = normal_builder_factory(
626 dimensions = {"os": "Linux", "inside_docker": "0"},
627)
628
629android_builder, android_try_job = normal_builder_factory(
630 dimensions = {"os": "Linux"},
631)
632
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100633win_builder = normal_builder_factory(
634 dimensions = {"os": "Windows"},
635)[0]
Mirko Bonadei5aafd472021-04-21 10:42:00 +0200636
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100637win_try_job = normal_builder_factory(
638 dimensions = {"os": "Windows"},
639 goma_enable_ats = False,
640)[1]
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100641
642mac_builder, mac_try_job = normal_builder_factory(
643 dimensions = {"os": "Mac"},
644)
645
Jeremy Leconte2b0245c2022-02-28 15:04:31 +0100646ios_builder, ios_try_job = normal_builder_factory(
Jeremy Leconte2338cc02022-02-22 13:22:05 +0100647 dimensions = {"os": "Mac-10.15"},
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100648 properties = {"xcode_build_version": WEBRTC_IOS_XCODE_VERSION},
Jeremy Leconte2338cc02022-02-22 13:22:05 +0100649 caches = [swarming.cache(
650 name = "xcode_ios_" + WEBRTC_IOS_XCODE_VERSION,
651 path = "xcode_ios_" + WEBRTC_IOS_XCODE_VERSION + ".app",
652 )],
Jeremy Leconte2b0245c2022-02-28 15:04:31 +0100653)
Mirko Bonadei84360ca2020-03-12 08:35:48 +0100654
Mirko Bonadeia7677a32021-10-05 08:31:36 +0200655ios_builder_macos11, ios_try_job_macos11 = normal_builder_factory(
Mirko Bonadeie680bce2021-10-03 12:05:13 +0200656 dimensions = {"os": "Mac-11"},
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100657 properties = {"xcode_build_version": WEBRTC_XCODE13},
Jeremy Lecontea9cd35e2022-02-22 15:15:21 +0100658 caches = [swarming.cache(
659 name = "xcode_ios_" + WEBRTC_XCODE13,
660 path = "xcode_ios_" + WEBRTC_XCODE13 + ".app",
661 )],
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100662)
663
664# Actual builder configuration:
665
666android_builder("Android32 (M Nexus5X)(dbg)", "Android|arm|dbg")
667android_try_job("android_compile_arm_dbg", cq = None)
668android_try_job("android_arm_dbg")
669android_builder("Android32 (M Nexus5X)", "Android|arm|rel")
Andrey Logvin849978d2021-09-14 10:20:19 +0000670android_try_job("android_arm_rel")
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100671android_builder("Android32 Builder arm", "Android|arm|size", perf_cat = "Android|arm|Builder|", prioritized = True)
672android_try_job("android_compile_arm_rel")
Jeremy Leconte39fbd002022-02-22 10:01:14 +0100673perf_builder("Perf Android32 (M Nexus5)", "Android|arm|Tester|M Nexus5", triggered_by = ["Android32 Builder arm"])
674perf_builder("Perf Android32 (M AOSP Nexus6)", "Android|arm|Tester|M AOSP Nexus6", triggered_by = ["Android32 Builder arm"])
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100675android_try_job("android_compile_arm64_dbg", cq = None)
676android_try_job("android_arm64_dbg", cq = None)
677android_builder("Android64 (M Nexus5X)", "Android|arm64|rel")
678android_try_job("android_arm64_rel")
679android_builder("Android64 Builder arm64", "Android|arm64|size", perf_cat = "Android|arm64|Builder|", prioritized = True)
Jeremy Leconte39fbd002022-02-22 10:01:14 +0100680perf_builder("Perf Android64 (M Nexus5X)", "Android|arm64|Tester|M Nexus5X", triggered_by = ["Android64 Builder arm64"])
681perf_builder("Perf Android64 (O Pixel2)", "Android|arm64|Tester|O Pixel2", triggered_by = ["Android64 Builder arm64"])
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100682android_try_job("android_compile_arm64_rel")
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100683android_builder("Android64 Builder x64 (dbg)", "Android|x64|dbg")
684android_try_job("android_compile_x64_dbg")
685android_try_job("android_compile_x64_rel", cq = None)
686android_builder("Android32 Builder x86 (dbg)", "Android|x86|dbg")
687android_try_job("android_compile_x86_dbg")
688android_builder("Android32 Builder x86", "Android|x86|rel")
689android_try_job("android_compile_x86_rel")
Jeremy Leconteec86a692022-02-28 09:09:52 +0100690android_builder("Android32 (more configs)", "Android|arm|more")
691android_try_job("android_arm_more_configs")
Oleh Prypin7d1cabe2019-03-14 15:10:30 +0100692android_try_job("android_chromium_compile", recipe = "chromium_trybot", branch_cq = False)
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100693
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100694ios_builder("iOS64 Debug", "iOS|arm64|dbg")
695ios_try_job("ios_compile_arm64_dbg")
696ios_builder("iOS64 Release", "iOS|arm64|rel")
697ios_try_job("ios_compile_arm64_rel")
Artem Titov1d47d312020-11-03 14:45:52 +0100698ios_builder("iOS64 Sim Debug (iOS 14.0)", "iOS|x64|14")
Andrey Logvin81320ad2021-06-02 16:45:09 +0000699ios_try_job("ios_sim_x64_dbg_ios14")
Artem Titov1d47d312020-11-03 14:45:52 +0100700ios_builder("iOS64 Sim Debug (iOS 13)", "iOS|x64|13")
Andrey Logvin81320ad2021-06-02 16:45:09 +0000701ios_try_job("ios_sim_x64_dbg_ios13")
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100702ios_builder("iOS64 Sim Debug (iOS 12)", "iOS|x64|12")
Andrey Logvin81320ad2021-06-02 16:45:09 +0000703ios_try_job("ios_sim_x64_dbg_ios12")
Mirko Bonadeia7677a32021-10-05 08:31:36 +0200704ios_builder_macos11("iOS API Framework Builder", "iOS|fat|size", recipe = "ios_api_framework", prioritized = True)
705ios_try_job_macos11("ios_api_framework", recipe = "ios_api_framework")
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100706
707linux_builder("Linux32 Debug", "Linux|x86|dbg")
708linux_try_job("linux_x86_dbg")
709linux_builder("Linux32 Release", "Linux|x86|rel")
710linux_try_job("linux_x86_rel")
711linux_builder("Linux64 Debug", "Linux|x64|dbg")
712linux_try_job("linux_dbg", cq = None)
713linux_try_job("linux_compile_dbg")
714linux_builder("Linux64 Release", "Linux|x64|rel")
715linux_try_job("linux_rel")
716linux_builder("Linux64 Builder", "Linux|x64|size", perf_cat = "Linux|x64|Builder|", prioritized = True)
717linux_try_job("linux_compile_rel")
Jeremy Leconte39fbd002022-02-22 10:01:14 +0100718perf_builder("Perf Linux Trusty", "Linux|x64|Tester|Trusty", triggered_by = ["Linux64 Builder"])
719perf_builder("Perf Linux Bionic", "Linux|x64|Tester|Bionic", triggered_by = ["Linux64 Builder"])
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100720linux_builder("Linux32 Debug (ARM)", "Linux|arm|dbg")
721linux_try_job("linux_compile_arm_dbg")
722linux_builder("Linux32 Release (ARM)", "Linux|arm|rel")
723linux_try_job("linux_compile_arm_rel")
724linux_builder("Linux64 Debug (ARM)", "Linux|arm64|dbg")
725linux_try_job("linux_compile_arm64_dbg")
726linux_builder("Linux64 Release (ARM)", "Linux|arm64|rel")
727linux_try_job("linux_compile_arm64_rel")
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100728linux_builder("Linux Asan", "Linux|x64|asan")
729linux_try_job("linux_asan")
730linux_builder("Linux MSan", "Linux|x64|msan")
731linux_try_job("linux_msan")
732linux_builder("Linux Tsan v2", "Linux|x64|tsan")
733linux_try_job("linux_tsan2")
734linux_builder("Linux UBSan", "Linux|x64|ubsan")
735linux_try_job("linux_ubsan")
736linux_builder("Linux UBSan vptr", "Linux|x64|ubsan")
737linux_try_job("linux_ubsan_vptr")
738linux_builder("Linux64 Release (Libfuzzer)", "Linux|x64|fuzz", recipe = "libfuzzer")
739linux_try_job("linux_libfuzzer_rel", recipe = "libfuzzer")
Jeremy Leconteec86a692022-02-28 09:09:52 +0100740linux_builder("Linux (more configs)", "Linux|x64|more")
741linux_try_job("linux_more_configs")
Oleh Prypin7d1cabe2019-03-14 15:10:30 +0100742linux_try_job("linux_chromium_compile", recipe = "chromium_trybot", branch_cq = False)
Mirko Bonadei40de50f2019-11-07 11:23:47 +0100743linux_try_job("linux_chromium_compile_dbg", recipe = "chromium_trybot", branch_cq = False)
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100744
745mac_builder("Mac64 Debug", "Mac|x64|dbg")
Mirko Bonadei36a79c52021-10-15 19:52:52 +0200746mac_try_job("mac_dbg", cq = None)
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100747mac_try_job("mac_compile_dbg")
748mac_builder("Mac64 Release", "Mac|x64|rel")
Mirko Bonadei624568e2021-10-15 15:31:57 +0200749mac_try_job("mac_rel")
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100750mac_try_job("mac_compile_rel", cq = None)
751mac_builder("Mac64 Builder", ci_cat = None, perf_cat = "Mac|x64|Builder|")
Jeremy Leconte39fbd002022-02-22 10:01:14 +0100752perf_builder("Perf Mac 10.11", "Mac|x64|Tester|10.11", triggered_by = ["Mac64 Builder"])
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100753mac_builder("Mac Asan", "Mac|x64|asan")
Andrey Logvina9501222021-04-27 18:08:39 +0000754mac_try_job("mac_asan")
Christoffer Jansson4a8d1f52021-12-09 10:16:43 +0100755mac_try_job("mac_chromium_compile", recipe = "chromium_trybot", branch_cq = False)
Jeremy Leconte228f54f2022-02-23 11:10:33 +0100756mac_builder("MacARM64 M1 Release", "Mac|arm64M1|rel", cpu = "arm64-64-Apple_M1")
Jeremy Leconte39fbd002022-02-22 10:01:14 +0100757mac_try_job("mac_rel_m1", try_cat = None, cq = None)
758mac_try_job("mac_dbg_m1", try_cat = None, cq = None)
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100759
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100760win_builder("Win32 Debug (Clang)", "Win Clang|x86|dbg")
761win_try_job("win_x86_clang_dbg", cq = None)
762win_try_job("win_compile_x86_clang_dbg")
763win_builder("Win32 Release (Clang)", "Win Clang|x86|rel")
764win_try_job("win_x86_clang_rel")
765win_try_job("win_compile_x86_clang_rel", cq = None)
766win_builder("Win32 Builder (Clang)", ci_cat = None, perf_cat = "Win|x86|Builder|")
Jeremy Leconte1efa6a12022-02-23 09:17:12 +0100767perf_builder("Perf Win7", "Win|x86|Tester|7", triggered_by = ["Win32 Builder (Clang)"])
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100768win_builder("Win64 Debug (Clang)", "Win Clang|x64|dbg")
769win_try_job("win_x64_clang_dbg", cq = None)
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100770win_try_job("win_x64_clang_dbg_win10", cq = None)
771win_try_job("win_compile_x64_clang_dbg")
772win_builder("Win64 Release (Clang)", "Win Clang|x64|rel")
773win_try_job("win_x64_clang_rel", cq = None)
774win_try_job("win_compile_x64_clang_rel")
Mirko Bonadeiafbe33d2019-05-31 09:27:54 +0200775win_builder("Win64 ASan", "Win Clang|x64|asan")
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100776win_try_job("win_asan")
Jeremy Leconteec86a692022-02-28 09:09:52 +0100777win_builder("Win (more configs)", "Win Clang|x86|more")
778win_try_job("win_x86_more_configs")
Mirko Bonadei825f9c22020-07-01 11:52:39 +0200779win_try_job("win_chromium_compile", recipe = "chromium_trybot", branch_cq = False, goma_jobs = 150)
780win_try_job("win_chromium_compile_dbg", recipe = "chromium_trybot", branch_cq = False, goma_jobs = 150)
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100781
782linux_try_job(
783 "presubmit",
784 recipe = "run_presubmit",
785 properties = {"repo_name": "webrtc", "runhooks": True},
786 priority = 28,
787 cq = {"disable_reuse": True},
788)
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100789
790cron_builder(
791 "Auto-roll - WebRTC DEPS",
792 recipe = "auto_roll_webrtc_deps",
Oleh Prypindc68a722019-06-25 10:43:13 +0200793 schedule = "0 */2 * * *", # Every 2 hours.
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100794)
Oleh Prypin8f0dc312019-05-31 15:54:35 +0200795
Mirko Bonadei54bbd1c2020-12-14 15:54:46 +0100796cron_builder(
797 "WebRTC version update",
798 recipe = "update_webrtc_binary_version",
799 schedule = "0 4 * * *", # Every day at 4am.
800 service_account = "webrtc-version-updater@webrtc-ci.iam.gserviceaccount.com",
801)
802
Oleh Prypin8f0dc312019-05-31 15:54:35 +0200803lkgr_config = {
804 "project": "webrtc",
805 "source_url": WEBRTC_GIT,
806 "status_url": "https://webrtc-status.appspot.com",
Christoffer Jansson75938042021-10-21 16:56:34 +0200807 "allowed_lag": 150, # hours
808 "allowed_gap": 4, # commits behind
Mirko Bonadeif4b78bf2021-04-29 11:23:41 +0200809 "error_recipients": WEBRTC_TROOPER_EMAIL,
Michael Achenbach09dd7dc2019-07-26 15:26:11 +0200810 "buckets": {
811 "webrtc/ci": {
812 # bucket alias: luci.webrtc.ci
Mirko Bonadeiab3ff262020-12-18 10:17:43 +0100813 "builders": [
814 b
815 for b in sorted(lkgr_builders)
816 if b not in skipped_lkgr_bots
817 ],
Oleh Prypin8f0dc312019-05-31 15:54:35 +0200818 },
Michael Achenbach09dd7dc2019-07-26 15:26:11 +0200819 "chromium/webrtc.fyi": {
820 # bucket alias: luci.chromium.webrtc.fyi
Oleh Prypin8f0dc312019-05-31 15:54:35 +0200821 "builders": [
822 "WebRTC Chromium FYI Android Builder (dbg)",
823 "WebRTC Chromium FYI Android Builder ARM64 (dbg)",
824 "WebRTC Chromium FYI Android Builder",
Mirko Bonadeidbda38f2022-01-24 13:16:58 +0100825 "WebRTC Chromium FYI Android Tests (dbg) (M Nexus5X)",
826 "WebRTC Chromium FYI Android Tests (dbg) (N Nexus5X)",
Oleh Prypin8f0dc312019-05-31 15:54:35 +0200827 "WebRTC Chromium FYI Linux Builder (dbg)",
828 "WebRTC Chromium FYI Linux Builder",
Mirko Bonadeidbda38f2022-01-24 13:16:58 +0100829 "WebRTC Chromium FYI Linux Tester",
Oleh Prypin8f0dc312019-05-31 15:54:35 +0200830 "WebRTC Chromium FYI Mac Builder (dbg)",
831 "WebRTC Chromium FYI Mac Builder",
Mirko Bonadeidbda38f2022-01-24 13:16:58 +0100832 "WebRTC Chromium FYI Mac Tester",
Oleh Prypin8f0dc312019-05-31 15:54:35 +0200833 "WebRTC Chromium FYI Win Builder (dbg)",
Andrey Logvin7228ba12021-09-15 17:59:21 +0000834 "WebRTC Chromium FYI Win Builder",
Mirko Bonadeidbda38f2022-01-24 13:16:58 +0100835 "WebRTC Chromium FYI Win10 Tester",
836 "WebRTC Chromium FYI Win7 Tester",
Mirko Bonadei2f05cfe2020-11-25 10:41:58 +0100837 "WebRTC Chromium FYI ios-device",
Björn Tereliusc20ed6b2021-06-21 14:31:35 +0200838 "WebRTC Chromium FYI ios-simulator",
Oleh Prypin8f0dc312019-05-31 15:54:35 +0200839 ],
840 },
841 },
842}
843
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100844cron_builder(
845 "WebRTC lkgr finder",
846 recipe = "lkgr_finder",
Oleh Prypin8f0dc312019-05-31 15:54:35 +0200847 properties = {
848 "project": "webrtc",
849 "repo": WEBRTC_GIT,
850 "ref": "refs/heads/lkgr",
Christoffer Janssone9fcc7b2021-06-29 13:02:15 +0200851 "src_ref": "refs/heads/main",
Oleh Prypin8f0dc312019-05-31 15:54:35 +0200852 "lkgr_status_gs_path": "chromium-webrtc/lkgr-status",
853 "config": lkgr_config,
854 },
Oleh Prypin1a0593f2019-03-11 09:43:28 +0100855 schedule = "*/10 * * * *", # Every 10 minutes.
856)