Merge "Schedule icn-bluval-daily-master at midnight"
[icn.git] / ci / jjb / akraino-icn-templates.yaml
1 ---
2 - job-template:
3     id: icn-stream-vagrant-verify-target
4     name: 'icn-{stream}-vagrant-verify-{target}'
5     defaults: icn
6     archive-artifacts: >
7       **/*.log
8     build-days-to-keep: 30
9     build-timeout: 60
10     stream: master
11     target: verifier
12     project-type: freestyle
13     submodule-recursive: true
14     #node: '{build-node}'
15
16     properties:
17       - lf-infra-properties:
18           build-days-to-keep: '{build-days-to-keep}'
19
20     parameters:
21       - lf-infra-parameters:
22           project: '{project}'
23           stream: '{stream}'
24           branch: '{branch}'
25           lftools-version: '{lftools-version}'
26
27       - string:
28           name: ARCHIVE_ARTIFACTS
29           default: '{archive-artifacts}'
30           description: Artifacts to archive to the logs server.
31
32       - string:
33           name: NEXUS_LOG_SUBDIR
34           default: '{nexus_log_subdir}'
35           description: Organization sub dir on Akraino Nexus server.
36
37     wrappers:
38       - lf-infra-wrappers:
39           build-timeout: '{build-timeout}'
40           jenkins-ssh-credential: '{jenkins-ssh-credential}'
41
42     scm:
43       - lf-infra-gerrit-scm:
44           jenkins-ssh-credential: '{jenkins-ssh-credential}'
45           git-url: '{git-url}/{project}.git'
46           refspec: '$GERRIT_REFSPEC'
47           branch: '$GERRIT_BRANCH'
48           submodule-recursive: '{submodule-recursive}'
49           submodule-timeout: '{submodule-timeout}'
50           submodule-disable: false
51           choosing-strategy: 'gerrit'
52
53     triggers:
54       - timed: "@midnight"
55
56     builders:
57       - shell: !include-raw:
58           - shell/vagrant-verify.sh
59
60     publishers:
61       - postbuildscript:
62           builders:
63             - role: BOTH
64               build-on:
65                 - ABORTED
66                 - FAILURE
67                 - NOT_BUILT
68                 - SUCCESS
69                 - UNSTABLE
70               build-steps:
71                 # all files should be owned by jenkins, for cleanup
72                 - shell: 'sudo chown jenkins -R .'
73       - icn-infra-publish
74 #      - email:
75 #          recipients: icn.jenkins@intel.com
76
77 - job-template:
78     id: icn-stream-bm-verify-target
79     name: 'icn-{stream}-bm-verify-{target}'
80     defaults: icn
81     archive-artifacts: >
82       **/*.log
83     build-days-to-keep: 30
84     build-timeout: 60
85     stream: master
86     target: verifier
87     project-type: freestyle
88     submodule-recursive: true
89     #node: '{build-node}'
90
91     properties:
92       - lf-infra-properties:
93           build-days-to-keep: '{build-days-to-keep}'
94
95     parameters:
96       - lf-infra-parameters:
97           project: '{project}'
98           stream: '{stream}'
99           branch: '{branch}'
100           lftools-version: '{lftools-version}'
101
102       - string:
103           name: ARCHIVE_ARTIFACTS
104           default: '{archive-artifacts}'
105           description: Artifacts to archive to the logs server.
106
107       - string:
108           name: NEXUS_LOG_SUBDIR
109           default: '{nexus_log_subdir}'
110           description: Organization sub dir on Akraino Nexus server.
111
112     wrappers:
113       - lf-infra-wrappers:
114           build-timeout: '{build-timeout}'
115           jenkins-ssh-credential: '{jenkins-ssh-credential}'
116
117     scm:
118       - lf-infra-gerrit-scm:
119           jenkins-ssh-credential: '{jenkins-ssh-credential}'
120           git-url: '{git-url}/{project}.git'
121           refspec: '$GERRIT_REFSPEC'
122           branch: '$GERRIT_BRANCH'
123           submodule-recursive: '{submodule-recursive}'
124           submodule-timeout: '{submodule-timeout}'
125           submodule-disable: false
126           choosing-strategy: 'gerrit'
127
128     triggers:
129       - timed: "@midnight"
130
131     builders:
132       - shell: !include-raw:
133           - shell/bm-verify.sh
134
135     publishers:
136       - postbuildscript:
137           builders:
138             - role: BOTH
139               build-on:
140                 - ABORTED
141                 - FAILURE
142                 - NOT_BUILT
143                 - SUCCESS
144                 - UNSTABLE
145               build-steps:
146                 # all files should be owned by jenkins, for cleanup
147                 - shell: 'sudo chown jenkins -R .'
148       - icn-infra-publish
149 #      - email:
150 #          recipients: icn.jenkins@intel.com
151
152 - job-template:
153     id: icn-bluval-run-daily-tests
154     name: 'icn-bluval-daily-{stream}'
155     concurrent: true
156     node: '{build-node}'
157     defaults: icn
158     parameters:
159       - lf-infra-parameters: *validation_lf_infra_parameters
160       - string:
161           name: CLUSTER_MASTER_IP
162           default: '{bluval-cluster-master-ip}'
163           description: 'IP address to connect to the cluster master'
164       - string:
165           name: CLUSTER_SSH_USER
166           default: '{bluval-cluster-ssh-user}'
167           description: 'SSH username to connect to the cluster master '
168       - string:
169           name: CLUSTER_SSH_KEY
170           default: '{bluval-cluster-ssh-key}'
171           description: 'SSH key to connect to the cluster master'
172       - string:
173           name: BLUEPRINT
174           default: '{bluval-blueprint}'
175           description: 'Blueprint used'
176       - string:
177           name: LAYER
178           default: '{bluval-layer}'
179           description: 'Layer ("os", "k8s" or blank to run all)'
180       - string:
181           name: VERSION
182           default: '{bluval-version}'
183           description: 'Version or branch'
184       - string:
185           name: OPTIONAL
186           default: '{bluval-optional}'
187           description: 'If set to yes run optional tests'
188       - string:
189           name: PULL
190           default: '{bluval-pull}'
191           description: 'If set to yes pull docker images before run'
192       - string:
193           name: LAB_SILO
194           default: '{bluval-lab-silo}'
195           description: 'Name of silo in Nexus'
196
197     scm:
198       - lf-infra-github-scm:
199           jenkins-ssh-credential: '{jenkins-ssh-credential}'
200           url: '{git-url}/{project}.git'
201           refspec: '$GERRIT_REFSPEC'
202           branch: '$GERRIT_BRANCH'
203           submodule-recursive: false
204           submodule-timeout: '{submodule-timeout}'
205           submodule-disable: true
206           choosing-strategy: default
207
208     triggers:
209       - timed: "@midnight"
210
211     builders:
212       - description-setter:
213           description: "POD: $NODE_NAME<br/>BLUEPRINT: $BLUEPRINT<br/>LAB: $LAB_SILO<br/>LAYER: $LAYER"
214       - shell: !include-raw-escape:
215           shell/bluval.sh
216
217     publishers:
218       - robot:
219           output-path: 'results'
220           report-html: '**/report.html'
221           log-html: '**/log.html'
222           output-xml: '**/output.xml'
223       - logparser:
224           use-project-rules: true
225           parse-rules: "./bluval/rules.txt"
226           unstable-on-warning: false
227           fail-on-error: true
228           show-graphs: true
229       - postbuildscript:
230           mark-unstable-if-failed: true
231           builders:
232               - build-on:
233                     - SUCCESS
234                     - UNSTABLE
235                     - FAILURE
236                 build-steps:
237                     - shell: !include-raw-escape:
238                         shell/bluval-postbuild.sh