Bug 1492639: Only run cron bouncer checks on mozilla-beta; r=sfraser,mtabara

Differential Revision: https://phabricator.services.mozilla.com/D9137

--HG--
extra : rebase_source : beafd006b2cc29d195f2eaf7354bec21064f3ea0
extra : amend_source : 8ce35a3150ae9dbf194480ddbe96058c6cb9d395
This commit is contained in:
Tom Prince 2018-10-18 13:21:36 -06:00
Родитель ef13c0fd65
Коммит 63f91d28c5
3 изменённых файлов: 18 добавлений и 2 удалений

Просмотреть файл

@ -12,7 +12,6 @@ transforms:
job-defaults:
name: bouncer-check
description: bouncer check
run-on-projects: [] # to make sure this never runs as part of CI
worker-type: aws-provisioner-v1/gecko-{level}-b-linux
worker:
max-run-time: 1200
@ -23,6 +22,7 @@ job-defaults:
attributes:
build_platform: linux64
build_type: opt
cron: true
treeherder:
symbol: Rel(ckbouncer)
kind: test
@ -34,6 +34,7 @@ jobs:
index:
product: firefox
job-name: firefox-bouncer-check
run-on-projects: [release]
run:
config:
by-project:
@ -59,6 +60,7 @@ jobs:
devedition:
shipping-product: devedition
run-on-projects: [mozilla-beta]
index:
product: devedition
job-name: devedition-bouncer-check

Просмотреть файл

@ -238,3 +238,8 @@ In automation, full crashsymbol package generation is normally disabled. For
build kinds where the full crashsymbols should be enabled, set this attribute
to True. The full symbol packages will then be generated and uploaded on
release branches and on try.
cron
====
Indicates that a task is meant to be run via cron tasks, and should not be run
on push.

Просмотреть файл

@ -28,6 +28,13 @@ def filter_out_nightly(task, parameters):
return not task.attributes.get('nightly') or parameters.get('include_nightly')
def filter_out_cron(task, parameters):
"""
Filter out tasks that run via cron.
"""
return not task.attributes.get('cron')
def filter_for_project(task, parameters):
"""Filter tasks by project. Optionally enable nightlies."""
run_on_projects = set(task.attributes.get('run_on_projects', []))
@ -91,7 +98,7 @@ def filter_beta_release_tasks(task, parameters, ignore_kinds=None, allow_l10n=Fa
def standard_filter(task, parameters):
return all(
filter_func(task, parameters) for filter_func in
(filter_out_nightly, filter_for_project)
(filter_out_nightly, filter_out_cron, filter_for_project)
)
@ -568,6 +575,8 @@ def target_tasks_bouncer_check(full_task_graph, parameters, graph_config):
"""Select the set of tasks required to perform bouncer version verification.
"""
def filter(task):
if not filter_for_project(task, parameters):
return False
# For now any task in the repo-update kind is ok
return task.kind in ['cron-bouncer-check']
return [l for l, t in full_task_graph.tasks.iteritems() if filter(t)]