зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1458395 - Do not use stub installer on esr60. r=aki
On ESR[60] stub installer isn't designed to work, and we expect most users of esr will have no use for a stub installer. However this poses some problems where the taskgraph assumes that any Nightly generates a stub installer and thus it should be available along the way. The patch hardcodes the list of branches that do not need a stub installer, though we'll want to clean up this specification in some way, as Thunderbird will likely need it to be cleaner and we may want on-change builds to use this logic (e.g. for on-change l10n). Differential Revision: https://phabricator.services.mozilla.com/D1082 --HG-- extra : source : 2f091908b8839650961c3968b6beee1dd8d1084b
This commit is contained in:
Родитель
bf1b8ed73f
Коммит
e9432bbb09
|
@ -47,7 +47,12 @@ jobs:
|
|||
|
||||
firefox:
|
||||
bouncer-platforms: ['linux', 'linux64', 'osx', 'win', 'win64']
|
||||
bouncer-products: ['complete-mar', 'installer', 'installer-ssl', 'partial-mar', 'stub-installer']
|
||||
bouncer-products:
|
||||
by-project:
|
||||
default: ['complete-mar', 'installer', 'installer-ssl', 'partial-mar', 'stub-installer']
|
||||
# No stub installer in esr60
|
||||
mozilla-esr60: ['complete-mar', 'installer', 'installer-ssl', 'partial-mar']
|
||||
jamun: ['complete-mar', 'installer', 'installer-ssl', 'partial-mar']
|
||||
shipping-product: firefox
|
||||
|
||||
firefox-rc:
|
||||
|
|
|
@ -270,7 +270,7 @@ def make_task_description(config, jobs):
|
|||
|
||||
def generate_upstream_artifacts(job, build_task_ref, build_signing_task_ref,
|
||||
repackage_task_ref, repackage_signing_task_ref,
|
||||
platform, locale=None):
|
||||
platform, locale=None, project=None):
|
||||
|
||||
build_mapping = UPSTREAM_ARTIFACT_UNSIGNED_PATHS
|
||||
build_signing_mapping = UPSTREAM_ARTIFACT_SIGNED_PATHS
|
||||
|
@ -306,10 +306,19 @@ def generate_upstream_artifacts(job, build_task_ref, build_signing_task_ref,
|
|||
tasktype, platform, platform_was_previously_matched_by_regex, platform_regex
|
||||
)
|
||||
if paths:
|
||||
usable_paths = paths[:]
|
||||
|
||||
no_stub = ("mozilla-esr60", "jamun")
|
||||
if project in no_stub:
|
||||
# Stub installer is only generated on win32 and not on esr
|
||||
# XXX We really should have a better solution for this
|
||||
if 'target.stub-installer.exe' in usable_paths:
|
||||
usable_paths.remove('target.stub-installer.exe')
|
||||
upstream_artifacts.append({
|
||||
"taskId": {"task-reference": ref},
|
||||
"taskType": tasktype,
|
||||
"paths": ["{}/{}".format(artifact_prefix, path) for path in paths],
|
||||
"paths": ["{}/{}".format(artifact_prefix, path)
|
||||
for path in usable_paths],
|
||||
"locale": locale or "en-US",
|
||||
})
|
||||
platform_was_previously_matched_by_regex = platform_regex
|
||||
|
@ -395,7 +404,8 @@ def make_task_worker(config, jobs):
|
|||
'release-properties': craft_release_properties(config, job),
|
||||
'upstream-artifacts': generate_upstream_artifacts(
|
||||
job, build_task_ref, build_signing_task_ref, repackage_task_ref,
|
||||
repackage_signing_task_ref, platform, locale
|
||||
repackage_signing_task_ref, platform, locale,
|
||||
project=config.params['project']
|
||||
),
|
||||
}
|
||||
if locale:
|
||||
|
|
|
@ -92,6 +92,9 @@ def make_task_worker(config, jobs):
|
|||
resolve_keyed_by(
|
||||
job, 'scopes', item_name=job['name'], project=config.params['project']
|
||||
)
|
||||
resolve_keyed_by(
|
||||
job, 'bouncer-products', item_name=job['name'], project=config.params['project']
|
||||
)
|
||||
|
||||
# No need to filter out ja-JP-mac, we need to upload both; but we do
|
||||
# need to filter out the platforms they come with
|
||||
|
|
|
@ -46,6 +46,7 @@ def define_upstream_artifacts(config, jobs):
|
|||
dep_job,
|
||||
keep_locale_template=False,
|
||||
kind=config.kind,
|
||||
project=config.params["project"],
|
||||
)
|
||||
|
||||
if 'android' in build_platform:
|
||||
|
|
|
@ -39,7 +39,8 @@ def define_upstream_artifacts(config, jobs):
|
|||
|
||||
locale_specifications = generate_specifications_of_artifacts_to_sign(
|
||||
dep_job,
|
||||
keep_locale_template=True
|
||||
keep_locale_template=True,
|
||||
project=config.params["project"],
|
||||
)
|
||||
|
||||
upstream_artifacts = []
|
||||
|
|
|
@ -185,8 +185,11 @@ def make_job_description(config, jobs):
|
|||
|
||||
worker = {
|
||||
'env': _generate_task_env(dep_job, build_platform, build_task_ref,
|
||||
signing_task_ref, locale=locale),
|
||||
'artifacts': _generate_task_output_files(dep_job, build_platform, locale=locale),
|
||||
signing_task_ref, locale=locale,
|
||||
project=config.params["project"]),
|
||||
'artifacts': _generate_task_output_files(dep_job, build_platform,
|
||||
locale=locale,
|
||||
project=config.params["project"]),
|
||||
'chain-of-trust': True,
|
||||
'max-run-time': 7200 if build_platform.startswith('win') else 3600,
|
||||
}
|
||||
|
@ -242,7 +245,8 @@ def make_job_description(config, jobs):
|
|||
yield task
|
||||
|
||||
|
||||
def _generate_task_env(task, build_platform, build_task_ref, signing_task_ref, locale=None):
|
||||
def _generate_task_env(task, build_platform, build_task_ref, signing_task_ref, locale=None,
|
||||
project=None):
|
||||
mar_prefix = get_taskcluster_artifact_prefix(
|
||||
task, build_task_ref, postfix='host/bin/', locale=None
|
||||
)
|
||||
|
@ -263,17 +267,22 @@ def _generate_task_env(task, build_platform, build_task_ref, signing_task_ref, l
|
|||
'UNSIGNED_MAR': {'task-reference': '{}mar.exe'.format(mar_prefix)},
|
||||
}
|
||||
|
||||
# Stub installer is only generated on win32
|
||||
if '32' in build_platform:
|
||||
task_env['SIGNED_SETUP_STUB'] = {
|
||||
'task-reference': '{}setup-stub.exe'.format(signed_prefix),
|
||||
}
|
||||
no_stub = ("mozilla-esr60", "jamun")
|
||||
if project in no_stub:
|
||||
# Stub installer is only generated on win32 and not on esr
|
||||
task_env['NO_STUB_INSTALLER'] = '1'
|
||||
else:
|
||||
# Stub installer is only generated on win32
|
||||
if '32' in build_platform:
|
||||
task_env['SIGNED_SETUP_STUB'] = {
|
||||
'task-reference': '{}setup-stub.exe'.format(signed_prefix),
|
||||
}
|
||||
return task_env
|
||||
|
||||
raise NotImplementedError('Unsupported build_platform: "{}"'.format(build_platform))
|
||||
|
||||
|
||||
def _generate_task_output_files(task, build_platform, locale=None):
|
||||
def _generate_task_output_files(task, build_platform, locale=None, project=None):
|
||||
locale_output_path = '{}/'.format(locale) if locale else ''
|
||||
artifact_prefix = get_artifact_prefix(task)
|
||||
|
||||
|
@ -304,8 +313,9 @@ def _generate_task_output_files(task, build_platform, locale=None):
|
|||
'name': '{}/{}target.complete.mar'.format(artifact_prefix, locale_output_path),
|
||||
}]
|
||||
|
||||
# Stub installer is only generated on win32
|
||||
if '32' in build_platform:
|
||||
# Stub installer is only generated on win32 and not on esr
|
||||
no_stub = ("mozilla-esr60", "jamun")
|
||||
if 'win32' in build_platform and project not in no_stub:
|
||||
output_files.append({
|
||||
'type': 'file',
|
||||
'path': '{}/{}target.stub-installer.exe'.format(
|
||||
|
|
|
@ -112,8 +112,10 @@ def make_repackage_signing_description(config, jobs):
|
|||
})
|
||||
scopes.append(add_scope_prefix(config, "signing:format:sha2signcode"))
|
||||
|
||||
# Stub installer is only generated on win32
|
||||
if '32' in build_platform:
|
||||
# Stub installer is only generated on win32 and not on esr
|
||||
no_stub = ("mozilla-esr60", "jamun")
|
||||
if 'win32' in build_platform and not config.params["project"] in no_stub:
|
||||
# TODO: fix the project hint to be a better design
|
||||
upstream_artifacts.append({
|
||||
"taskId": {"task-reference": "<repackage>"},
|
||||
"taskType": "repackage",
|
||||
|
|
|
@ -15,7 +15,7 @@ def is_partner_kind(kind):
|
|||
|
||||
|
||||
def generate_specifications_of_artifacts_to_sign(
|
||||
task, keep_locale_template=True, kind=None
|
||||
task, keep_locale_template=True, kind=None, project=None
|
||||
):
|
||||
build_platform = task.attributes.get('build_platform')
|
||||
is_nightly = task.attributes.get('nightly')
|
||||
|
@ -56,7 +56,10 @@ def generate_specifications_of_artifacts_to_sign(
|
|||
],
|
||||
'formats': ['sha2signcode', 'widevine'],
|
||||
}]
|
||||
if 'win32' in build_platform and is_nightly:
|
||||
no_stub = ("mozilla-esr60", "jamun")
|
||||
if 'win32' in build_platform and is_nightly and project not in no_stub:
|
||||
# TODO: fix the project hint to be a better design
|
||||
# We don't build stub installer on esr, so we don't want to sign it
|
||||
artifacts_specifications[0]['artifacts'] += [
|
||||
get_artifact_path(task, '{locale}/setup-stub.exe')
|
||||
]
|
||||
|
|
|
@ -6,9 +6,14 @@ download_config = {
|
|||
"target.zip": os.environ.get("SIGNED_ZIP"),
|
||||
"setup.exe": os.environ.get("SIGNED_SETUP"),
|
||||
"mar.exe": os.environ.get("UNSIGNED_MAR"),
|
||||
}
|
||||
|
||||
if not os.environ.get("NO_STUB_INSTALLER"):
|
||||
# Some channels, like esr don't build a stub installer
|
||||
download_config.update({
|
||||
# stub installer is only built on win32
|
||||
"setup-stub.exe": os.environ.get("SIGNED_SETUP_STUB"),
|
||||
}
|
||||
})
|
||||
|
||||
repackage_config = [[
|
||||
"installer",
|
||||
|
@ -23,13 +28,17 @@ repackage_config = [[
|
|||
"-i", "{abs_work_dir}\\inputs\\target.zip",
|
||||
"--mar", "{abs_work_dir}\\inputs\\mar.exe",
|
||||
"-o", "{output_home}\\target.complete.mar",
|
||||
], [
|
||||
]]
|
||||
|
||||
if not os.environ.get("NO_STUB_INSTALLER"):
|
||||
# Some channels, like esr don't build a stub installer
|
||||
repackage_config.append([
|
||||
"installer",
|
||||
"--tag", "{abs_mozilla_dir}\\browser\\installer\\windows\\stub.tag",
|
||||
"--setupexe", "{abs_work_dir}\\inputs\\setup-stub.exe",
|
||||
"-o", "{output_home}\\target.stub-installer.exe",
|
||||
"--setupexe", "{abs_work_dir}\\inputs\\setup-stub.exe",
|
||||
"-o", "{output_home}\\target.stub-installer.exe",
|
||||
"--sfx-stub", "other-licenses/7zstub/firefox/7zSD.sfx",
|
||||
]]
|
||||
])
|
||||
|
||||
config = {
|
||||
"input_home": "{abs_work_dir}\\inputs",
|
||||
|
|
Загрузка…
Ссылка в новой задаче