Add manual triggered csit-vpp-functional-hw-tb2 job. 73/373/2
authorStefan Kobza <skobza@cisco.com>
Mon, 22 Feb 2016 15:26:45 +0000 (16:26 +0100)
committerStefan Kobza <skobza@cisco.com>
Tue, 23 Feb 2016 14:15:43 +0000 (14:15 +0000)
This job would be create from the same template as
csit-vpp-functional-virl, but for the time being this have to be
manually triggered. I didn't find a way how to parametrize
gerrit-trigger-patch-submitted so I've created
gerrit-trigger-manually-triggered.

Change-Id: I2d4f2c6bb8ebb94cd8563132feac765d46e1b56d
Signed-off-by: Stefan Kobza <skobza@cisco.com>
jjb/csit/csit-vpp-functional.yaml
jjb/csit/include-raw-csit-vpp-functional-hw-tb2.sh [new file with mode: 0644]
jjb/global-macros.yaml

index 59bd10d..f6136eb 100644 (file)
 
         - robot-report
 
+- job:
+    name: 'csit-vpp-functional-hw-tb2'
+
+    project-type: freestyle
+    node: verify
+    concurrent: false
+
+    logrotate:
+        daysToKeep: '{build-days-to-keep}'
+        numToKeep: '{build-num-to-keep}'
+        artifactDaysToKeep: '{build-artifact-days-to-keep}'
+        artifactNumToKeep: '{build-artifact-num-to-keep}'
+
+    parameters:
+        - project-parameter:
+            project: '{project}'
+        - gerrit-parameter:
+            branch: '{branch}'
+        - string:
+            name: 'VPP_URLS'
+            default: ''
+            description: 'Space separated VPP *.deb URLs from nexus'
+
+    scm:
+        - gerrit-trigger-scm:
+            credentials-id: '{ssh-credentials}'
+            refspec: '$GERRIT_REFSPEC'
+            choosing-strategy: 'gerrit'
+
+    wrappers:
+        - ssh-agent-credentials:
+            users:
+                - '{ssh-credentials}'
+    triggers:
+        - gerrit-trigger-manually-triggered:
+            name: '{project}'
+            branch: '{branch}'
+            comment-trigger-value: 'hw-tb2-recheck'
+
+    builders:
+        - shell:
+            !include-raw-escape jjb/csit/include-raw-csit-vpp-functional-hw-tb2.sh
+
+    publishers:
+        - archive-artifacts:
+            artifacts: 'report.html, log.html, output.xml'
+            latest-only: false
+
+        - robot-report
diff --git a/jjb/csit/include-raw-csit-vpp-functional-hw-tb2.sh b/jjb/csit/include-raw-csit-vpp-functional-hw-tb2.sh
new file mode 100644 (file)
index 0000000..8fa41cb
--- /dev/null
@@ -0,0 +1,15 @@
+#!/bin/bash
+
+# execute csit bootstrap script if it exists
+if [ -e bootstrap-hw-tb2.sh ]
+then
+    # make sure that bootstrap.sh is executable
+    chmod +x bootstrap-hw-tb2.sh
+    # run the script
+    ./bootstrap-hw-tb2.sh
+else
+    echo 'ERROR: No bootstrap-hw-tb2.sh found'
+    exit 1
+fi
+
+# vim: ts=4 ts=4 sts=4 et :
index 2b1d91c..7184668 100644 (file)
                     - branch-compare-type: 'ANT'
                       branch-pattern: '**/{branch}'
 
+- trigger:
+    name: gerrit-trigger-manually-triggered
+    triggers:
+        - gerrit:
+            server-name: 'Default'
+            trigger-on:
+                - comment-added-contains-event:
+                    comment-contains-value: '{comment-trigger-value}'
+            projects:
+                - project-compare-type: 'ANT'
+                  project-pattern: '{name}'
+                  branches:
+                    - branch-compare-type: 'ANT'
+                      branch-pattern: '**/{branch}'
+
 - trigger:
     name: gerrit-trigger-patch-merged
     triggers: