CSIT jobs - branching 27/1527/5
authorMiroslav Miklus <mmiklus@cisco.com>
Mon, 13 Jun 2016 14:56:28 +0000 (16:56 +0200)
committerMiroslav Miklus <mmiklus@cisco.com>
Tue, 14 Jun 2016 12:39:25 +0000 (14:39 +0200)
- introduce per branch jobs: master, stable/1606
- weekly job to create csit-stable branch
- archive artifacts for last 10 jobs

Change-Id: Ib3eb7320fad365017d82a5a594123f0c68076151
Signed-off-by: Miroslav Miklus <mmiklus@cisco.com>
jjb/csit/csit-vpp-pylint.yaml
jjb/csit/csit.yaml [moved from jjb/csit/csit-vpp-functional.yaml with 92% similarity]
jjb/csit/include-raw-csit-vpp-verify-weekly.sh

index fb9fb27..dda7176 100644 (file)
@@ -2,13 +2,13 @@
     name: csit-validate
 
     jobs:
-        - 'csit-validate-pylint'
+        - 'csit-validate-pylint-master'
 
     project: 'csit'
     branch: 'master'
 
 - job-template:
-    name: 'csit-validate-pylint'
+    name: 'csit-validate-pylint-master'
 
     project-type: freestyle
     node: verify
similarity index 92%
rename from jjb/csit/csit-vpp-functional.yaml
rename to jjb/csit/csit.yaml
index 05cff34..5e4a943 100644 (file)
@@ -1,20 +1,30 @@
 - project:
-    name: csit-vpp-functional
-    description: 'Run VPP functional tests on VIRL.'
+    name: csit
+    description: 'CSIT jenkins jobs.'
 
     jobs:
-        - 'csit-vpp-perf-hw-{type}'
-        - 'csit-vpp-functional-virl'
-        - 'csit-vpp-verify-weekly'
+        - 'csit-vpp-perf-{stream}-{type}'
+        - 'csit-vpp-functional-{stream}-virl'
+        - 'csit-vpp-verify-master-weekly'
         - 'csit-vpp-master-verify-semiweekly'
 
     project: 'csit'
     branch: 'master'
+    branch-id: 'master'
+    build-artifact-num-to-keep: 10
     type:
         - all
+        - long
+    stream:
+        - master:
+            branch: 'master'
+            branch-id: 'master'
+        - '1606':
+            branch: 'stable/1606'
+            branch-id: 'stable1606'
 
 - job-template:
-    name: 'csit-vpp-functional-virl'
+    name: 'csit-vpp-functional-{stream}-virl'
 
     project-type: freestyle
     node: verify
@@ -61,7 +71,7 @@
             output-path: ''
 
 - job-template:
-    name: 'csit-vpp-perf-hw-{type}'
+    name: 'csit-vpp-perf-{stream}-{type}'
 
     project-type: freestyle
     node: verify
                     xpath: '//*[@framesize="78" and contains(@tags,"PDR") and @workerthreads="4"]'
 
 - job-template:
-    name: 'csit-vpp-verify-weekly'
-    description: 'Purpose of this job is to validate CSIT code against verified vpp build and apply csit-verified tag in case of success.'
+    name: 'csit-vpp-verify-master-weekly'
+    description: 'Purpose of this job is to validate CSIT code against verified vpp build and create csit-verified branch in case of success.'
 
     project-type: freestyle
     node: verify
     scm:
         - git-scm:
             credentials-id: '{ssh-credentials}'
-            branch: 'master'
+            branch: '{branch}'
 
     wrappers:
         - ssh-agent-credentials:
     builders:
         - shell:
             !include-raw-escape jjb/csit/include-raw-csit-vpp-verify-weekly.sh
+        - shell: 'echo "DATE=`date +%Y-%m-%d`" > $WORKSPACE/variables.prop'
+        - inject:
+            properties-file: variables.prop
 
     publishers:
         - archive-artifacts:
-            artifacts: 'csit/report.html, csit/log.html, csit/output.xml'
+            artifacts: 'report.html, log.html, output.xml'
             latest-only: false
 
         - robot-report:
-            output-path: 'csit'
-
+            output-path: ''
         - git:
                push-only-if-success: true
                branches:
                 - branch:
                     remote: origin
-                    name: 'csit-verified-`date +%y%m%d`'
+                    name: 'csit-verified-{branch-id}-$DATE'
+
 
 - job-template:
     name: 'csit-vpp-master-verify-semiweekly'
index 6719933..3c74c34 100644 (file)
@@ -1,11 +1,6 @@
 #!/bin/bash
 set -xeu -o pipefail
 
-# Clone csit and start tests
-git clone https://gerrit.fd.io/r/csit --branch master
-
-cd csit
-
 # execute csit bootstrap script if it exists
 if [ -e bootstrap-vpp-verify-weekly.sh ]
 then
@@ -14,7 +9,7 @@ then
     # run the script
     ./bootstrap-vpp-verify-weekly.sh
 else
-    echo 'ERROR: No bootstrap-verify-master.sh found'
+    echo 'ERROR: No bootstrap-vpp-verify-weekly.sh found'
     exit 1
 fi