Fix packer verify file path triggering 60/6860/2
authorAndrew Grimberg <agrimberg@linuxfoundation.org>
Fri, 13 Oct 2017 20:38:21 +0000 (13:38 -0700)
committerAndrew Grimberg <agrimberg@linuxfoundation.org>
Fri, 13 Oct 2017 20:53:50 +0000 (13:53 -0700)
Packer verifies are not properly triggering because the generated ANT
paths are non-resolvable

Change-Id: I3938ca653ab0fba7190ea8caf3715bf7757be4f7
Signed-off-by: Andrew Grimberg <agrimberg@linuxfoundation.org>
.jjb-test/expected-xml/gerrit-ciman-packer-verify
jjb/lf-ci-jobs.yaml

index ccbb179..330c64c 100644 (file)
@@ -140,15 +140,15 @@ For example '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
           <filePaths>
             <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
               <compareType>ANT</compareType>
-              <pattern>packer/vars/['centos', 'ubuntu1604'].json</pattern>
+              <pattern>packer/vars/**.json</pattern>
             </com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
             <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
               <compareType>ANT</compareType>
-              <pattern>packer/templates/['java-builder', 'mininet'].json</pattern>
+              <pattern>packer/templates/**.json</pattern>
             </com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
             <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
               <compareType>ANT</compareType>
-              <pattern>packer/provision/['java-builder', 'mininet'].sh</pattern>
+              <pattern>packer/provision/**.sh</pattern>
             </com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
             <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
               <compareType>ANT</compareType>
index 479e3c0..b0d699a 100644 (file)
             - file-id: jjbini-sandbox
               target: '$HOME/.config/jenkins_jobs/jenkins_jobs.ini'
 
+- lf_packer_verify_file_paths: &lf_packer_verify_file_paths
+    name: lf-packer-verify-file-paths
+    file-paths:
+      # Common files for all projects
+      - compare-type: ANT
+        pattern: 'packer/vars/**.json'
+      - compare-type: ANT
+        pattern: 'packer/templates/**.json'
+      - compare-type: ANT
+        pattern: 'packer/provision/**.sh'
+      - compare-type: ANT
+        pattern: 'packer/provision/lib/**'
+
 - lf_packer_file_paths: &lf_packer_file_paths
     name: lf-packer-file-paths
     file-paths:
               branches:
                 - branch-compare-type: ANT
                   branch-pattern: '**/{branch}'
-              <<: *lf_packer_file_paths
+              <<: *lf_packer_verify_file_paths
 
 - job-template:
     name: '{project-name}-packer-verify'