Bug 1247168 - Actually use workspace cache in decision task; r=dustin draft
authorGregory Szorc <gps@mozilla.com>
Wed, 20 Jul 2016 15:34:10 -0700
changeset 392531 8cd8be43dfd34f2970b47721c3da8e3957a8bfed
parent 392530 742627ba823d4f2097a4273e6cc6af8bb842c69f
child 392532 05114e4e0e7fbbab2c89f25074abfeb7b9ba62ef
push id24049
push userbmo:gps@mozilla.com
push dateMon, 25 Jul 2016 19:51:28 +0000
reviewersdustin
bugs1247168
milestone50.0a1
Bug 1247168 - Actually use workspace cache in decision task; r=dustin The decision task configures a /home/worker/workspace cache. However, the command we run in the container references a "workspace" relative path. From logs in automation, it appears that PWD during execution is "/" because "workspace" is being resolved to "/workspace." The net result of this is we appear to be performing a VCS clone+checkout on every single task. This commit fixes the paths so our workspace cache is actually used. MozReview-Commit-ID: Kj6REep5bSs
.taskcluster.yml
taskcluster/taskgraph/action.yml
--- a/.taskcluster.yml
+++ b/.taskcluster.yml
@@ -84,18 +84,18 @@ tasks:
 
         maxRunTime: 1800
 
         command:
           - /bin/bash
           - -cx
           - >
             mkdir -p /home/worker/artifacts &&
-            checkout-gecko workspace &&
-            cd workspace/gecko &&
+            checkout-gecko /home/worker/workspace &&
+            cd /home/worker/workspace/gecko &&
             ln -s /home/worker/artifacts artifacts &&
             ./mach taskgraph decision
             --pushlog-id='{{pushlog_id}}'
             --project='{{project}}'
             --message='{{comment}}'
             --owner='{{owner}}'
             --level='{{level}}'
             --base-repository='https://hg.mozilla.org/mozilla-central'
--- a/taskcluster/taskgraph/action.yml
+++ b/taskcluster/taskgraph/action.yml
@@ -49,18 +49,18 @@ payload:
   # repository which is cached.
   maxRunTime: 1800
 
   command:
     - /bin/bash
     - -cx
     - >
       mkdir -p /home/worker/artifacts &&
-      checkout-gecko workspace &&
-      cd workspace/gecko &&
+      checkout-gecko /home/worker/workspace &&
+      cd /home/worker/workspace/gecko &&
       ln -s /home/worker/artifacts artifacts &&
       ./mach taskgraph action-task
       --decision-id='{{decision_task_id}}'
       --task-labels='{{task_labels}}'
 
   artifacts:
     'public':
       type: 'directory'