bug 1442793 - partials artifact_prefix. r=bhearsum, a=release
authorAki Sasaki <asasaki@mozilla.com>
Wed, 21 Mar 2018 15:13:57 -0700
changeset 463411 20526f7322541f6727f700c7c147f8d20198dc57
parent 463410 865a973ff4502c2e2f954efe8869ad0c8ea63dc1
child 463412 7e2fd5fbfc0fe7b3d1033289c35ef691914db36a
push id1683
push usersfraser@mozilla.com
push dateThu, 26 Apr 2018 16:43:40 +0000
treeherdermozilla-release@5af6cb21869d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbhearsum, release
bugs1442793
milestone60.0
bug 1442793 - partials artifact_prefix. r=bhearsum, a=release MozReview-Commit-ID: 2XL2OEpVyWO
taskcluster/taskgraph/transforms/partials.py
--- a/taskcluster/taskgraph/transforms/partials.py
+++ b/taskcluster/taskgraph/transforms/partials.py
@@ -4,38 +4,39 @@
 """
 Transform the partials task into an actual task description.
 """
 from __future__ import absolute_import, print_function, unicode_literals
 
 from taskgraph.transforms.base import TransformSequence
 from taskgraph.util.attributes import copy_attributes_from_dependent_job
 from taskgraph.util.partials import get_balrog_platform_name, get_builds
-from taskgraph.util.taskcluster import get_taskcluster_artifact_prefix
+from taskgraph.util.taskcluster import get_taskcluster_artifact_prefix, get_artifact_prefix
 
 import logging
 logger = logging.getLogger(__name__)
 
 transforms = TransformSequence()
 
 
-def _generate_task_output_files(filenames, locale=None):
+def _generate_task_output_files(job, filenames, locale=None):
     locale_output_path = '{}/'.format(locale) if locale else ''
+    artifact_prefix = get_artifact_prefix(job)
 
     data = list()
     for filename in filenames:
         data.append({
             'type': 'file',
             'path': '/home/worker/artifacts/{}'.format(filename),
-            'name': 'public/build/{}{}'.format(locale_output_path, filename)
+            'name': '{}/{}{}'.format(artifact_prefix, locale_output_path, filename)
         })
     data.append({
         'type': 'file',
         'path': '/home/worker/artifacts/manifest.json',
-        'name': 'public/build/{}manifest.json'.format(locale_output_path)
+        'name': '{}/{}manifest.json'.format(artifact_prefix, locale_output_path)
     })
     return data
 
 
 @transforms.add
 def make_task_description(config, jobs):
     # If no balrog release history, then don't generate partials
     if not config.params.get('release_history'):
@@ -117,17 +118,17 @@ def make_task_description(config, jobs):
             else:
                 mar_channel_id = 'firefox-mozilla-beta'
         elif config.params['project'] == 'mozilla-release':
             mar_channel_id = 'firefox-mozilla-release'
         elif 'esr' in config.params['project']:
             mar_channel_id = 'firefox-mozilla-esr'
 
         worker = {
-            'artifacts': _generate_task_output_files(builds.keys(), locale),
+            'artifacts': _generate_task_output_files(dep_job, builds.keys(), locale),
             'implementation': 'docker-worker',
             'docker-image': {'in-tree': 'funsize-update-generator'},
             'os': 'linux',
             'max-run-time': 3600,
             'chain-of-trust': True,
             'taskcluster-proxy': True,
             'env': {
                 'SHA1_SIGNING_CERT': 'nightly_sha1',