54dbe0f8958a50bd6eb5d1b77c9eb4b7e4aec018
[releng/builder.git] / jjb / packaging / packaging.yaml
1 ---
2 - project:
3     name: packaging
4     project-name: packaging
5
6     jobs:
7       - '{project-name}-rtd-jobs':
8           build-node: centos7-builder-2c-2g
9           doc-dir: .tox/docs/tmp/html
10           project-pattern: integration/packaging
11           rtd-build-url: https://readthedocs.org/api/v2/webhook/odl-integrationpackaging/32928/
12           rtd-token: 371d63c43ad99b0745bb7779e3488c5e255c1180
13       - 'packaging-build-rpm-{stream}'
14       - 'packaging-build-rpm-{distro}-snap-{stream}'
15       - 'packaging-build-deb-{stream}'
16       - 'packaging-verify-full-rpm-master'
17       - 'packaging-verify-rpm-master'
18       - 'packaging-test-rpm-master'
19       - 'packaging-test-rpm-upgrade-master'
20       - 'packaging-test-deb-master'
21       - gerrit-tox-verify:
22           branch: master
23           stream: master
24
25     project: 'integration/packaging'
26
27     stream:
28       - fluorine
29       - oxygen
30     distro:
31       - opensuse-42
32       - epel-7
33     branch: 'master'
34
35     # common parameters required for 'lf-infra-deploy-maven-file' builder
36     group-id: 'org.opendaylight.integration-packaging'
37     upload-files-dir: '$WORKSPACE/upload_files'
38     maven-repo-url: '$NEXUS_URL/content/repositories/$REPO_ID'
39
40 - job-template:
41     name: 'packaging-build-rpm-{stream}'
42
43     node: centos7-builder-2c-8g
44
45     project-type: freestyle
46
47     mvn-opts: ''
48     mvn-params: ''
49     mvn-version: mvn33
50
51     properties:
52       - opendaylight-infra-properties:
53           build-days-to-keep: 7
54
55     parameters:
56       - opendaylight-infra-parameters:
57           os-cloud: '{os-cloud}'
58           project: '{project}'
59           branch: '{branch}'
60           refspec: 'refs/heads/{branch}'
61           artifacts: '{archive-artifacts}'
62       - lf-infra-maven-parameters:
63           mvn-opts: '{mvn-opts}'
64           mvn-params: '{mvn-params}'
65           mvn-version: '{mvn-version}'
66           staging-profile-id: ''
67       - string:
68           name: DOWNLOAD_URL
69           # yamllint disable-line rule:line-length
70           default: 'https://nexus.opendaylight.org/content/repositories/opendaylight.release/org/opendaylight/integration/karaf/0.8.2/karaf-0.8.2.tar.gz'
71           description: 'URL to ODL tarball artifact to repackage into RPM'
72       - string:
73           name: CHANGELOG_NAME
74           default: 'Jenkins'
75           description: 'Name of person who defined RPM'
76       - string:
77           name: CHANGELOG_EMAIL
78           default: 'jenkins-donotreply@opendaylight.org'
79           description: 'Email of person who defined RPM'
80
81     scm:
82       - integration-gerrit-scm:
83           basedir: 'packaging'
84           refspec: '$GERRIT_REFSPEC'
85           branch: 'master'
86
87     wrappers:
88       - opendaylight-infra-wrappers:
89           build-timeout: '{build-timeout}'
90
91     builders:
92       - shell: !include-raw-escape: build-rpm.sh
93       - install-test-uninstall-rpm
94       - lf-infra-deploy-maven-file:
95           global-settings-file: 'global-settings'
96           settings-file: 'packaging-settings'
97           mvn-version: '{mvn-version}'
98           repo-id: 'opendaylight-{stream}-epel-7-x86_64-devel'
99           group-id: '{group-id}'
100           upload-files-dir: '{upload-files-dir}'
101           maven-repo-url: '{maven-repo-url}'
102
103     publishers:
104       - lf-infra-publish
105
106
107 - job-template:
108     name: 'packaging-build-rpm-{distro}-snap-{stream}'
109
110     node: centos7-docker-2c-8g
111
112     project-type: freestyle
113
114     mvn-opts: ''
115     mvn-params: ''
116     mvn-version: mvn33
117
118     properties:
119       - opendaylight-infra-properties:
120           build-days-to-keep: 7
121
122     parameters:
123       - opendaylight-infra-parameters:
124           os-cloud: '{os-cloud}'
125           project: '{project}'
126           branch: '{branch}'
127           refspec: 'refs/heads/{branch}'
128           artifacts: '{archive-artifacts}'
129       - lf-infra-maven-parameters:
130           mvn-opts: '{mvn-opts}'
131           mvn-params: '{mvn-params}'
132           mvn-version: '{mvn-version}'
133           staging-profile-id: ''
134       - string:
135           name: CHANGELOG_NAME
136           default: 'Jenkins'
137           description: 'Name of person who defined RPM'
138       - string:
139           name: CHANGELOG_EMAIL
140           default: 'jenkins-donotreply@opendaylight.org'
141           description: 'Email of person who defined RPM'
142
143     scm:
144       - integration-gerrit-scm:
145           basedir: 'packaging'
146           refspec: '$GERRIT_REFSPEC'
147           branch: 'master'
148
149     wrappers:
150       - opendaylight-infra-wrappers:
151           build-timeout: '{build-timeout}'
152
153     builders:
154       - inject:
155           properties-content: |
156               STREAM={stream}
157               DISTRO={distro}
158       - shell: !include-raw: build-rpm-snap-docker.sh
159       - shell: !include-raw: test-rpm-docker.sh
160       - lf-infra-deploy-maven-file:
161           global-settings-file: 'global-settings'
162           settings-file: 'packaging-settings'
163           mvn-version: '{mvn-version}'
164           repo-id: 'opendaylight-{stream}-{distro}-x86_64-devel'
165           group-id: '{group-id}'
166           upload-files-dir: '{upload-files-dir}'
167           maven-repo-url: '{maven-repo-url}'
168
169     triggers:
170       - timed: '@daily'
171
172     publishers:
173       - lf-infra-publish
174
175
176 - job-template:
177     name: 'packaging-verify-rpm-master'
178
179     node: centos7-builder-2c-8g
180
181     project-type: freestyle
182
183     parameters:
184       - opendaylight-infra-parameters:
185           os-cloud: '{os-cloud}'
186           project: '{project}'
187           branch: '{branch}'
188           refspec: 'refs/heads/{branch}'
189           artifacts: '{archive-artifacts}'
190
191     scm:
192       - integration-gerrit-scm:
193           basedir: 'packaging'
194           refspec: '$GERRIT_REFSPEC'
195           branch: 'master'
196
197     wrappers:
198       - opendaylight-infra-wrappers:
199           build-timeout: '{build-timeout}'
200
201     builders:
202       # Test Oxygen SR2 release tarball
203       - inject:
204           # yamllint disable-line rule:line-length
205           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/opendaylight.release/org/opendaylight/integration/karaf/0.8.2/karaf-0.8.2.tar.gz'
206       - shell: !include-raw-escape: build-rpm.sh
207       - install-test-uninstall-rpm
208
209       # Test latest Oxygen snapshot
210       - inject:
211           properties-content: 'STREAM=oxygen'
212       - shell: !include-raw: build-rpm-snap.sh
213       - install-test-uninstall-rpm
214
215       # Test Fluorine pre-release autorelease tarball
216       # NB: This will need to be updated as old builds expire
217       - inject:
218           # yamllint disable-line rule:line-length
219           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/autorelease-2209/org/opendaylight/integration/karaf/0.9.0/karaf-0.9.0.tar.gz'
220       - shell: !include-raw-escape: build-rpm.sh
221       - install-test-uninstall-rpm
222
223       # Test Fluorine multipatch zip (no parallel tarball available)
224       # NB: This will need to be updated as old builds expire
225       - inject:
226           # yamllint disable-line rule:line-length
227           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/opendaylight.snapshot/org/opendaylight/integration/integration/distribution/karaf/0.9.0-SNAPSHOT/karaf-0.9.0-20180620.055735-63.zip'
228       - shell: !include-raw-escape: build-rpm.sh
229       - install-test-uninstall-rpm
230
231       # Test latest Fluorine snapshot
232       - inject:
233           properties-content: 'STREAM=fluorine'
234       - shell: !include-raw: build-rpm-snap.sh
235       - install-test-uninstall-rpm
236
237     triggers:
238       - gerrit-trigger-patch-submitted:
239           gerrit-server-name: '{gerrit-server-name}'
240           project: '{project}'
241           branch: '{branch}'
242           files: 'packages/**'
243
244     publishers:
245       - lf-infra-publish
246
247
248 - job-template:
249     name: 'packaging-verify-full-rpm-master'
250
251     node: centos7-builder-2c-8g
252
253     project-type: freestyle
254
255     parameters:
256       - opendaylight-infra-parameters:
257           os-cloud: '{os-cloud}'
258           project: '{project}'
259           branch: '{branch}'
260           refspec: 'refs/heads/{branch}'
261           artifacts: '{archive-artifacts}'
262
263     scm:
264       - integration-gerrit-scm:
265           basedir: 'packaging'
266           refspec: '$GERRIT_REFSPEC'
267           branch: 'master'
268
269     wrappers:
270       - opendaylight-infra-wrappers:
271           build-timeout: '{build-timeout}'
272
273     builders:
274       # Test Oxygen SR2 release tarball
275       - inject:
276           # yamllint disable-line rule:line-length
277           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/opendaylight.release/org/opendaylight/integration/karaf/0.8.2/karaf-0.8.2.tar.gz'
278       - shell: !include-raw-escape: build-rpm.sh
279       - install-test-uninstall-rpm
280
281       # Test Oxygen pre-release autorelease tarball
282       # NB: This will need to be updated as old builds expire
283       - inject:
284           # yamllint disable-line rule:line-length
285           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/autorelease-2210/org/opendaylight/integration/karaf/0.8.3/karaf-0.8.3.tar.gz'
286       - shell: !include-raw-escape: build-rpm.sh
287       - install-test-uninstall-rpm
288
289       # Test Oxygen multipatch zip (no parallel tarball available)
290       # NB: This will need to be updated as old builds expire
291       - inject:
292           # yamllint disable-line rule:line-length
293           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/opendaylight.snapshot/org/opendaylight/integration/integration/distribution/karaf/0.8.3-SNAPSHOT/karaf-0.8.3-20180620.173319-5.zip'
294       - shell: !include-raw-escape: build-rpm.sh
295       - install-test-uninstall-rpm
296
297       # Test latest Oxygen snapshot
298       - inject:
299           properties-content: 'STREAM=oxygen'
300       - shell: !include-raw: build-rpm-snap.sh
301       - install-test-uninstall-rpm
302
303       # Test Fluorine pre-release autorelease tarball
304       # NB: This will need to be updated as old builds expire
305       - inject:
306           # yamllint disable-line rule:line-length
307           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/autorelease-2209/org/opendaylight/integration/karaf/0.9.0/karaf-0.9.0.tar.gz'
308       - shell: !include-raw-escape: build-rpm.sh
309       - install-test-uninstall-rpm
310
311       # Test Fluorine multipatch zip (no parallel tarball available)
312       # NB: This will need to be updated as old builds expire
313       - inject:
314           # yamllint disable-line rule:line-length
315           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/opendaylight.snapshot/org/opendaylight/integration/integration/distribution/karaf/0.9.0-SNAPSHOT/karaf-0.9.0-20180620.055735-63.zip'
316       - shell: !include-raw-escape: build-rpm.sh
317       - install-test-uninstall-rpm
318
319       # Test latest Fluorine snapshot
320       - inject:
321           properties-content: 'STREAM=fluorine'
322       - shell: !include-raw: build-rpm-snap.sh
323       - install-test-uninstall-rpm
324
325     triggers:
326       - timed: '@daily'
327       - gerrit:
328           server-name: '{gerrit-server-name}'
329           trigger-on:
330             - comment-added-contains-event:
331                 comment-contains-value: 'verify-rpm-full'
332           projects:
333             - project-compare-type: ANT
334               project-pattern: '{project}'
335               branches:
336                 - branch-compare-type: ANT
337                   branch-pattern: '**/{branch}'
338
339     publishers:
340       - lf-infra-publish
341
342
343 - job-template:
344     name: 'packaging-test-rpm-master'
345
346     node: centos7-builder-2c-8g
347
348     parameters:
349       - opendaylight-infra-parameters:
350           os-cloud: '{os-cloud}'
351           project: '{project}'
352           branch: '{branch}'
353           refspec: 'refs/heads/{branch}'
354           artifacts: '{archive-artifacts}'
355       - string:
356           name: URL
357           # yamllint disable-line rule:line-length
358           default: 'https://git.opendaylight.org/gerrit/gitweb?p=integration/packaging.git;a=blob_plain;f=packages/rpm/example_repo_configs/opendaylight-9-devel.repo'
359           description: 'Link to .repo or .rpm file'
360
361     scm:
362       - integration-gerrit-scm:
363           basedir: 'packaging'
364           refspec: '$GERRIT_REFSPEC'
365           branch: 'master'
366
367     wrappers:
368       - opendaylight-infra-wrappers:
369           build-timeout: '{build-timeout}'
370
371     builders:
372       - shell: |
373           # Install expect to interact with Karaf shell
374           # Install nmap to check status of ODL's SSH port
375           sudo yum install -y expect nmap
376       - shell: !include-raw-escape: install-rpm.sh
377       - shell: !include-raw: start-odl.sh
378       - shell: !include-raw-escape: test-ports-nofeature.sh
379       - shell: !include-raw: test-karaf-oxygensafe.expect
380       # Disable this test until ODLPARENT-139 is fixed
381       # - shell: !include-raw-escape: test-rest-ok.sh
382       - shell: !include-raw: stop-odl.sh
383       - shell: !include-raw: uninstall-rpm.sh
384
385     publishers:
386       # TODO: Remove the archive publisher
387       #       small data should be stored on logs.opendaylight.org
388       #       large data should be stored on nexus.opendaylight.org
389       - archive:
390           artifacts: '**'
391           allow-empty: true
392           fingerprint: true
393           latest-only: true
394       - lf-infra-publish
395
396
397 - job-template:
398     name: 'packaging-test-rpm-upgrade-master'
399
400     node: centos7-builder-2c-8g
401
402     parameters:
403       - opendaylight-infra-parameters:
404           os-cloud: '{os-cloud}'
405           project: '{project}'
406           branch: '{branch}'
407           refspec: 'refs/heads/{branch}'
408           artifacts: '{archive-artifacts}'
409       - string:
410           name: URL
411           # yamllint disable-line rule:line-length
412           default: 'https://raw.githubusercontent.com/opendaylight/integration-packaging/master/packages/rpm/example_repo_configs/opendaylight-8-release.repo'
413           description: 'Link to .repo or .rpm file'
414       - string:
415           name: UPGRADE_URL
416           # yamllint disable-line rule:line-length
417           default: 'https://raw.githubusercontent.com/opendaylight/integration-packaging/master/packages/rpm/example_repo_configs/opendaylight-8-devel.repo'
418           description: 'Link to .repo or .rpm file'
419
420     scm:
421       - integration-gerrit-scm:
422           basedir: 'packaging'
423           refspec: '$GERRIT_REFSPEC'
424           branch: 'master'
425
426     wrappers:
427       - opendaylight-infra-wrappers:
428           build-timeout: '{build-timeout}'
429
430     builders:
431       - shell: !include-raw-escape: install-rpm.sh
432       - shell: !include-raw: start-odl.sh
433       - shell: |
434           # Install expect to interact with Karaf shell
435           sudo yum install -y expect
436           # Install nmap to check status of ODL's SSH port
437           sudo yum install -y nmap
438       - shell: !include-raw: test-karaf-oxygensafe.expect
439       - shell: !include-raw: stop-odl.sh
440       - shell: !include-raw: test-rpm-upgrade.sh
441       - shell: !include-raw: start-odl.sh
442       - shell: !include-raw: test-karaf-oxygensafe.expect
443       - shell: !include-raw: stop-odl.sh
444       - shell: !include-raw: uninstall-rpm.sh
445
446     publishers:
447       - lf-infra-publish
448
449
450 - job-template:
451     name: 'packaging-test-deb-master'
452
453     node: ubuntu1604-mininet-ovs-25-1c-4g
454
455     parameters:
456       - opendaylight-infra-parameters:
457           os-cloud: '{os-cloud}'
458           project: '{project}'
459           branch: '{branch}'
460           refspec: 'refs/heads/{branch}'
461           artifacts: '{archive-artifacts}'
462       - string:
463           name: PACKAGE
464           default: 'ppa:odl-team/oxygen'
465           description: 'Link to .deb package or name of PPA repo'
466
467     scm:
468       - integration-gerrit-scm:
469           basedir: 'packaging'
470           refspec: '$GERRIT_REFSPEC'
471           branch: 'master'
472
473     wrappers:
474       - opendaylight-infra-wrappers:
475           build-timeout: '{build-timeout}'
476
477     builders:
478       - shell: !include-raw-escape: install-deb.sh
479       - shell: !include-raw: start-odl.sh
480       - shell: !include-raw-escape: test-ports-nofeature.sh
481       - shell: |
482           # Install expect to interact with Karaf shell
483           # Install nmap to check status of ODL's SSH port
484           sudo apt-get install -y expect nmap
485       - shell: !include-raw: test-karaf-oxygensafe.expect
486       # Disable this test until ODLPARENT-139 is fixed
487       # - shell: !include-raw-escape: test-rest-ok.sh
488       - shell: !include-raw: stop-odl.sh
489       - shell: !include-raw-escape: uninstall-deb.sh
490
491     publishers:
492       - lf-infra-publish
493
494
495 - job-template:
496     name: 'packaging-build-deb-{stream}'
497
498     node: ubuntu1604-mininet-ovs-25-1c-4g
499
500     project-type: freestyle
501
502     mvn-opts: ''
503     mvn-params: ''
504     mvn-version: mvn33
505
506     properties:
507       - opendaylight-infra-properties:
508           build-days-to-keep: 7
509
510     parameters:
511       - opendaylight-infra-parameters:
512           os-cloud: '{os-cloud}'
513           project: '{project}'
514           branch: '{branch}'
515           refspec: 'refs/heads/{branch}'
516           artifacts: '{archive-artifacts}'
517       - lf-infra-maven-parameters:
518           mvn-opts: '{mvn-opts}'
519           mvn-params: '{mvn-params}'
520           mvn-version: '{mvn-version}'
521           staging-profile-id: ''
522       - string:
523           name: DOWNLOAD_URL
524           # FIXME: Update the default value to an active stream.
525           # yamllint disable-line rule:line-length
526           default: 'https://nexus.opendaylight.org/content/repositories/opendaylight.release/org/opendaylight/integration/distribution-karaf/0.5.3-Boron-SR3/distribution-karaf-0.5.3-Boron-SR3.tar.gz'
527           description: 'URL to ODL tarball artifact to repackage into .deb'
528       - string:
529           name: CHANGELOG_NAME
530           default: 'Jenkins'
531           description: 'Name of person who defined .deb'
532       - string:
533           name: CHANGELOG_EMAIL
534           default: 'jenkins-donotreply@opendaylight.org'
535           description: 'Email of person who defined .deb'
536
537     scm:
538       - integration-gerrit-scm:
539           basedir: 'packaging'
540           refspec: '$GERRIT_REFSPEC'
541           branch: 'master'
542
543     wrappers:
544       - opendaylight-infra-wrappers:
545           build-timeout: '{build-timeout}'
546
547     builders:
548       - shell: !include-raw: build-deb.sh
549       - install-test-uninstall-deb
550       - lf-infra-deploy-maven-file:
551           global-settings-file: 'global-settings'
552           settings-file: 'packaging-settings'
553           mvn-version: '{mvn-version}'
554           repo-id: 'opendaylight-{stream}-ubuntu-1604-x86_64-devel'
555           group-id: '{group-id}'
556           upload-files-dir: '{upload-files-dir}'
557           maven-repo-url: '{maven-repo-url}'
558
559     publishers:
560       - lf-infra-publish