Bug 1425931: Cleanup yaml files; r=me
authorTom Prince <mozilla@hocat.ca>
Mon, 18 Dec 2017 12:27:00 -0700
changeset 30626 f64410aa2f07031ab257ef7bf01a18dc068439fd
parent 30625 059f0d567118681be8fa9326a223242be762b3db
child 30627 5e23d65bdcfcd95150f93b8866d3adb44168d8b9
push id382
push userclokep@gmail.com
push dateMon, 12 Mar 2018 19:05:34 +0000
reviewersme
bugs1425931
Bug 1425931: Cleanup yaml files; r=me MozReview-Commit-ID: BeuXvpvAY53
.taskcluster.yml
.yamllint
taskcluster/.yamllint
taskcluster/ci/build/kind.yml
taskcluster/ci/docker-image/kind.yml
taskcluster/ci/source-test/kind.yml
taskcluster/ci/test/tests.yml
--- a/.taskcluster.yml
+++ b/.taskcluster.yml
@@ -13,22 +13,22 @@ tasks:
       repoUrl: {$if: 'repository.url[-1] == "/"', then: {$eval: 'repository.url[:-1]'}, else: {$eval: 'repository.url'}}
     in:
       taskId: {$if: 'tasks_for != "action"', then: '${as_slugid("decision")}'}
       taskGroupId:
         $if: 'tasks_for == "action"'
         then:
           '${action.taskGroupId}'
         else:
-          '${as_slugid("decision")}' # same as taskId; this is how automation identifies a decision tsak
+          '${as_slugid("decision")}'  # same as taskId; this is how automation identifies a decision tsak
       schedulerId: 'gecko-level-${repository.level}'
 
       created: {$fromNow: ''}
       deadline: {$fromNow: '1 day'}
-      expires: {$fromNow: '1 year 1 second'} # 1 second so artifacts expire first, despite rounding errors
+      expires: {$fromNow: '1 year 1 second'}  # 1 second so artifacts expire first, despite rounding errors
 
       metadata:
         $merge:
           - owner: "${ownerEmail}"
             source: "${repoUrl}/raw-file/${push.revision}/.taskcluster.yml"
           - $if: 'tasks_for == "hg-push"'
             then:
               name: "Thunderbird Decision Task"
@@ -51,31 +51,31 @@ tasks:
         else:
           $if: 'tasks_for == "action"'
           then:
             createdForUser: '${ownerEmail}'
             kind: 'action-callback'
 
       routes:
         $flatten:
-        - "tc-treeherder.v2.${repository.project}.${push.revision}.${push.pushlog_id}"
-        - "tc-treeherder-stage.v2.${repository.project}.${push.revision}.${push.pushlog_id}"
-        - $if: 'tasks_for == "hg-push"'
-          then:
-          - "index.comm.v2.${repository.project}.latest.thunderbird.decision"
-          - "index.comm.v2.${repository.project}.revision.${push.revision}.thunderbird.decision"
-          - "index.comm.v2.${repository.project}.pushlog-id.${push.pushlog_id}.decision"
-          - "notify.email.${ownerEmail}.on-failed"
-          - $if: '"mozilla@hocat.ca" in ownerEmail'
-            # Until taskcluster is ready for general consumption, don't report exceptions from taskcluster.
-            then: "notify.email.${ownerEmail}.on-exception"
-          else:
-          - $if: 'tasks_for == "action"'
-            then: "index.comm.v2.${repository.project}.pushlog-id.${push.pushlog_id}.actions.$ownTaskId"
-            else: "index.comm.v2.${repository.project}.latest.thunderbird.decision-${cron.job_name}"
+          - "tc-treeherder.v2.${repository.project}.${push.revision}.${push.pushlog_id}"
+          - "tc-treeherder-stage.v2.${repository.project}.${push.revision}.${push.pushlog_id}"
+          - $if: 'tasks_for == "hg-push"'
+            then:
+              - "index.comm.v2.${repository.project}.latest.thunderbird.decision"
+              - "index.comm.v2.${repository.project}.revision.${push.revision}.thunderbird.decision"
+              - "index.comm.v2.${repository.project}.pushlog-id.${push.pushlog_id}.decision"
+              - "notify.email.${ownerEmail}.on-failed"
+              - $if: '"mozilla@hocat.ca" in ownerEmail'
+                # Until taskcluster is ready for general consumption, don't report exceptions from taskcluster.
+                then: "notify.email.${ownerEmail}.on-exception"
+            else:
+              - $if: 'tasks_for == "action"'
+                then: "index.comm.v2.${repository.project}.pushlog-id.${push.pushlog_id}.actions.$ownTaskId"
+                else: "index.comm.v2.${repository.project}.latest.thunderbird.decision-${cron.job_name}"
 
       scopes:
         $if: 'tasks_for == "hg-push"'
         then:
           - 'assume:repo:${repoUrl[8:]}:*'
           - 'queue:route:notify.email.${ownerEmail}.*'
         else:
           $if: 'tasks_for == "action"'
@@ -87,45 +87,45 @@ tasks:
       dependencies: []
       requires: all-completed
 
       priority: lowest
       retries: 5
 
       payload:
         env:
+          # checkout-gecko uses these to check out the source; the inputs
+          # to `mach taskgraph decision` are all on the command line.
           $merge:
-          - # checkout-gecko uses these to check out the source; the inputs
-            # to `mach taskgraph decision` are all on the command line.
-            GECKO_BASE_REPOSITORY: 'https://hg.mozilla.org/mozilla-unified'
-            GECKO_HEAD_REPOSITORY: 'https://hg.mozilla.org/mozilla-central'
-            GECKO_HEAD_REF: 'default'
-            COMM_BASE_REPOSITORY: 'https://hg.mozilla.org/comm-central'
-            COMM_HEAD_REPOSITORY: '${repoUrl}'
-            COMM_HEAD_REF: '${push.revision}'
-            COMM_HEAD_REV: '${push.revision}'
-            HG_STORE_PATH: /buillds/worker/checkouts/hg-store
-            TASKCLUSTER_CACHES: /builds/worker/checkouts
-          - $if: 'tasks_for != "action"'
-            then: 
-              $if: '("--buildbot" in push.comment) && !("mozilla@hocat.ca" in ownerEmail)'
+            - GECKO_BASE_REPOSITORY: 'https://hg.mozilla.org/mozilla-unified'
+              GECKO_HEAD_REPOSITORY: 'https://hg.mozilla.org/mozilla-central'
+              GECKO_HEAD_REF: 'default'
+              COMM_BASE_REPOSITORY: 'https://hg.mozilla.org/comm-central'
+              COMM_HEAD_REPOSITORY: '${repoUrl}'
+              COMM_HEAD_REF: '${push.revision}'
+              COMM_HEAD_REV: '${push.revision}'
+              HG_STORE_PATH: /buillds/worker/checkouts/hg-store
+              TASKCLUSTER_CACHES: /builds/worker/checkouts
+            - $if: 'tasks_for != "action"'
               then:
-                # Until all buildbot platforms are supported in taskcluster, avoid
-                # passing try syntax to taskcluster.
-                COMM_COMMIT_MSG: 'try: ignored'
-              else:
-                COMM_COMMIT_MSG: '${push.comment}'
-          - $if: 'tasks_for == "action"'
-            then:
-              ACTION_TASK_GROUP_ID: '${action.taskGroupId}'
-              ACTION_TASK_ID: {$json: {$eval: 'taskId'}}
-              ACTION_TASK: {$json: {$eval: 'task'}}
-              ACTION_INPUT: {$json: {$eval: 'input'}}
-              ACTION_CALLBACK: '${action.cb_name}'
-              ACTION_PARAMETERS: {$json: {$eval: 'parameters'}}
+                $if: '("--buildbot" in push.comment) && !("mozilla@hocat.ca" in ownerEmail)'
+                then:
+                  # Until all buildbot platforms are supported in taskcluster, avoid
+                  # passing try syntax to taskcluster.
+                  COMM_COMMIT_MSG: 'try: ignored'
+                else:
+                  COMM_COMMIT_MSG: '${push.comment}'
+            - $if: 'tasks_for == "action"'
+              then:
+                ACTION_TASK_GROUP_ID: '${action.taskGroupId}'
+                ACTION_TASK_ID: {$json: {$eval: 'taskId'}}
+                ACTION_TASK: {$json: {$eval: 'task'}}
+                ACTION_INPUT: {$json: {$eval: 'input'}}
+                ACTION_CALLBACK: '${action.cb_name}'
+                ACTION_PARAMETERS: {$json: {$eval: 'parameters'}}
 
         cache:
           level-${repository.level}-checkouts-sparse-v1: /builds/worker/checkouts
 
         features:
           taskclusterProxy: true
           chainOfTrust: true
 
new file mode 100644
--- /dev/null
+++ b/.yamllint
@@ -0,0 +1,8 @@
+---
+extends: default
+
+rules:
+  document-end:
+     present: false
+  # Checks currently failing
+  line-length: disable
--- a/taskcluster/.yamllint
+++ b/taskcluster/.yamllint
@@ -3,8 +3,10 @@ extends: default
 
 rules:
   document-end:
      present: false
   document-start:
      present: false
   # Checks currently failing
   line-length: disable
+  indentation:
+     spaces: 4
--- a/taskcluster/ci/build/kind.yml
+++ b/taskcluster/ci/build/kind.yml
@@ -16,31 +16,31 @@ transforms:
     - taskgraph.transforms.task:transforms
 
 jobs-from:
     - linux.yml
     - macosx.yml
 
 job-defaults:
     when:
-      files-changed:
-        # Include everything in comm-central except suite/ and im/
-        # https://bugzilla.mozilla.org/show_bug.cgi?id=1422060
-        - comm/build
-        - comm/calendar
-        - comm/chat
-        - comm/common
-        - comm/config
-        - comm/db
-        - comm/editor
-        - comm/ldap
-        - comm/mail
-        - comm/mailnews
-        - comm/mozharness
-        - comm/other-licenses
-        - comm/python
-        - comm/taskcluster
-        - comm/testing
-        - comm/.taskcluster.yml
-        - comm/AUTHORS
-        - comm/comm-confvars.sh
-        - comm/moz.build
-        - comm/moz.configure
+        files-changed:
+            # Include everything in comm-central except suite/ and im/
+            # https://bugzilla.mozilla.org/show_bug.cgi?id=1422060
+            - comm/build
+            - comm/calendar
+            - comm/chat
+            - comm/common
+            - comm/config
+            - comm/db
+            - comm/editor
+            - comm/ldap
+            - comm/mail
+            - comm/mailnews
+            - comm/mozharness
+            - comm/other-licenses
+            - comm/python
+            - comm/taskcluster
+            - comm/testing
+            - comm/.taskcluster.yml
+            - comm/AUTHORS
+            - comm/comm-confvars.sh
+            - comm/moz.build
+            - comm/moz.configure
--- a/taskcluster/ci/docker-image/kind.yml
+++ b/taskcluster/ci/docker-image/kind.yml
@@ -1,11 +1,11 @@
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 loader: comm_taskgraph:reference_loader
 base-path: taskcluster/ci
 
 jobs:
-  - desktop1604-test
-  - desktop-build
-  - lint
+    - desktop1604-test
+    - desktop-build
+    - lint
--- a/taskcluster/ci/source-test/kind.yml
+++ b/taskcluster/ci/source-test/kind.yml
@@ -1,14 +1,14 @@
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 loader: taskgraph.loader.transform:loader
 
 transforms:
     - taskgraph.transforms.try_job:transforms
-   - taskgraph.transforms.source_test:transforms
-   - taskgraph.transforms.job:transforms
-   - taskgraph.transforms.task:transforms
+    - taskgraph.transforms.source_test:transforms
+    - taskgraph.transforms.job:transforms
+    - taskgraph.transforms.task:transforms
 
 jobs-from:
     - mozlint.yml
--- a/taskcluster/ci/test/tests.yml
+++ b/taskcluster/ci/test/tests.yml
@@ -4,39 +4,39 @@
 # for a description of the fields used here.
 
 # Note that these are in lexical order, as enforced by the task loader.
 
 # Adding a new test type or running tests on a new platform? Be sure to review
 # https://wiki.mozilla.org/Sheriffing/Job_Visibility_Policy
 job-defaults:
     when:
-      files-changed:
-        # Include everything in comm-central except suite/ and im/
-        # https://bugzilla.mozilla.org/show_bug.cgi?id=1422060
-        - comm/build
-        - comm/calendar
-        - comm/chat
-        - comm/common
-        - comm/config
-        - comm/db
-        - comm/editor
-        - comm/ldap
-        - comm/mail
-        - comm/mailnews
-        - comm/mozharness
-        - comm/other-licenses
-        - comm/python
-        - comm/taskcluster
-        - comm/testing
-        - comm/.taskcluster.yml
-        - comm/AUTHORS
-        - comm/comm-confvars.sh
-        - comm/moz.build
-        - comm/moz.configure
+        files-changed:
+            # Include everything in comm-central except suite/ and im/
+            # https://bugzilla.mozilla.org/show_bug.cgi?id=1422060
+            - comm/build
+            - comm/calendar
+            - comm/chat
+            - comm/common
+            - comm/config
+            - comm/db
+            - comm/editor
+            - comm/ldap
+            - comm/mail
+            - comm/mailnews
+            - comm/mozharness
+            - comm/other-licenses
+            - comm/python
+            - comm/taskcluster
+            - comm/testing
+            - comm/.taskcluster.yml
+            - comm/AUTHORS
+            - comm/comm-confvars.sh
+            - comm/moz.build
+            - comm/moz.configure
 
 xpcshell:
     description: "xpcshell test run"
     suite: xpcshell
     treeherder-symbol: tc-X(X)
     run-on-projects: built-projects
     docker-image:
         in-tree: "desktop1604-test"