Bug 1301782 - Be explicit about what tags to create. r=aki
authorJustin Wood <Callek@gmail.com>
Thu, 21 Jun 2018 13:56:07 -0400
changeset 423315 eb64af8f8cec26d454e86dca7a3242180bdad348
parent 423314 2a08d68ca8f3bde85b102fd4958182b99bf0886c
child 423316 5abb841c6ec2cc629f33a0d519fb879d70e51d7d
push id34172
push userccoroiu@mozilla.com
push dateFri, 22 Jun 2018 09:55:27 +0000
treeherdermozilla-central@6b6f3f6ecf14 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersaki
bugs1301782
milestone62.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1301782 - Be explicit about what tags to create. r=aki for Tag RC releases Differential Revision: https://phabricator.services.mozilla.com/D1757
taskcluster/ci/release-version-bump/kind.yml
taskcluster/taskgraph/transforms/task.py
--- a/taskcluster/ci/release-version-bump/kind.yml
+++ b/taskcluster/ci/release-version-bump/kind.yml
@@ -20,17 +20,17 @@ job-defaults:
         by-project:
             mozilla-(beta|release|esr.*): scriptworker-prov-v1/treescript-v1
             maple: scriptworker-prov-v1/treescript-v1
             birch: scriptworker-prov-v1/treescript-v1
             jamun: scriptworker-prov-v1/treescript-v1
             default: scriptworker-prov-v1/treescript-dev
     worker:
         implementation: treescript
-        tag: true
+        tags: ['buildN', 'release']
         bump: true
         bump-files:
             by-project:
                 default: ["browser/config/version_display.txt"]
                 mozilla-release:
                     - "browser/config/version.txt"
                     - "browser/config/version_display.txt"
                     - "config/milestone.txt"
--- a/taskcluster/taskgraph/transforms/task.py
+++ b/taskcluster/taskgraph/transforms/task.py
@@ -540,17 +540,17 @@ task_description_schema = Schema({
             Required('taskType'): basestring,
             Required('paths'): [basestring],
         }],
     }, {
         Required('implementation'): 'shipit',
         Required('release-name'): basestring,
     }, {
         Required('implementation'): 'treescript',
-        Required('tag'): bool,
+        Required('tags'): [Any('buildN', 'release', None)],
         Required('bump'): bool,
         Optional('bump-files'): [basestring],
         Optional('repo-param-prefix'): basestring,
         Required('force-dry-run', default=True): bool,
         Required('push', default=False): bool
     }),
 })
 
@@ -1134,24 +1134,29 @@ def build_sign_and_push_addons_payload(c
 
 @payload_builder('treescript')
 def build_treescript_payload(config, task, task_def):
     worker = task['worker']
     release_config = get_release_config(config)
 
     task_def['payload'] = {}
     task_def.setdefault('scopes', [])
-    if worker['tag']:
+    if worker['tags']:
+        tag_names = []
         product = task['shipping-product'].upper()
         version = release_config['version'].replace('.', '_')
         buildnum = release_config['build_number']
-        tag_names = [
-            "{}_{}_BUILD{}".format(product, version, buildnum),
-            "{}_{}_RELEASE".format(product, version)
-        ]
+        if 'buildN' in worker['tags']:
+            tag_names.extend([
+                "{}_{}_BUILD{}".format(product, version, buildnum),
+            ])
+        if 'release' in worker['tags']:
+            tag_names.extend([
+              "{}_{}_RELEASE".format(product, version)
+            ])
         tag_info = {
             'tags': tag_names,
             'revision': config.params['{}head_rev'.format(worker.get('repo-param-prefix', ''))],
         }
         task_def['payload']['tag_info'] = tag_info
         task_def['scopes'].append(add_scope_prefix(config, 'treescript:action:tagging'))
 
     if worker['bump']: