0372f48ca8fcebc97b34f96a37d03be51347947f
[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.7.0/karaf-0.7.0.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 SR1 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.1/karaf-0.8.1.tar.gz'
206       - shell: !include-raw-escape: build-rpm.sh
207       - install-test-uninstall-rpm
208
209       # Test Fluorine pre-release autorelease tarball
210       # NB: This will need to be updated as old builds expire
211       - inject:
212           # yamllint disable-line rule:line-length
213           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/autorelease-2191/org/opendaylight/integration/karaf/0.9.0/karaf-0.9.0.tar.gz'
214       - shell: !include-raw-escape: build-rpm.sh
215       - install-test-uninstall-rpm
216
217       # Test Fluorine multipatch zip (no parallel tarball available)
218       # NB: This will need to be updated as old builds expire
219       - inject:
220           # yamllint disable-line rule:line-length
221           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-20180531.192226-59.zip'
222       - shell: !include-raw-escape: build-rpm.sh
223       - install-test-uninstall-rpm
224
225       # Test latest Fluorine snapshot
226       - inject:
227           properties-content: 'STREAM=fluorine'
228       - shell: !include-raw: build-rpm-snap.sh
229       - install-test-uninstall-rpm
230
231     triggers:
232       - gerrit:
233           server-name: '{gerrit-server-name}'
234           trigger-on:
235             - comment-added-contains-event:
236                 comment-contains-value: 'rpm-verify'
237           projects:
238             - project-compare-type: ANT
239               project-pattern: '{project}'
240               branches:
241                 - branch-compare-type: ANT
242                   branch-pattern: '**/{branch}'
243               file-paths:
244                 - compare-type: ANT
245                   pattern: 'packages/**'
246
247     publishers:
248       - lf-infra-publish
249
250
251 - job-template:
252     name: 'packaging-verify-full-rpm-master'
253
254     node: centos7-builder-2c-8g
255
256     project-type: freestyle
257
258     parameters:
259       - opendaylight-infra-parameters:
260           os-cloud: '{os-cloud}'
261           project: '{project}'
262           branch: '{branch}'
263           refspec: 'refs/heads/{branch}'
264           artifacts: '{archive-artifacts}'
265
266     scm:
267       - integration-gerrit-scm:
268           basedir: 'packaging'
269           refspec: '$GERRIT_REFSPEC'
270           branch: 'master'
271
272     wrappers:
273       - opendaylight-infra-wrappers:
274           build-timeout: '{build-timeout}'
275
276     builders:
277       # Test Oxygen SR1 release tarball
278       - inject:
279           # yamllint disable-line rule:line-length
280           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/opendaylight.release/org/opendaylight/integration/karaf/0.8.1/karaf-0.8.1.tar.gz'
281       - shell: !include-raw-escape: build-rpm.sh
282       - install-test-uninstall-rpm
283
284       # Test Oxygen pre-release autorelease tarball
285       # NB: This will need to be updated as old builds expire
286       - inject:
287           # yamllint disable-line rule:line-length
288           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/autorelease-2192/org/opendaylight/integration/karaf/0.8.2/karaf-0.8.2.tar.gz'
289       - shell: !include-raw-escape: build-rpm.sh
290       - install-test-uninstall-rpm
291
292       # Test Oxygen multipatch zip (no parallel tarball available)
293       # NB: This will need to be updated as old builds expire
294       - inject:
295           # yamllint disable-line rule:line-length
296           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/opendaylight.snapshot/org/opendaylight/integration/integration/distribution/karaf/0.8.2-SNAPSHOT/karaf-0.8.2-20180524.145206-1.zip'
297       - shell: !include-raw-escape: build-rpm.sh
298       - install-test-uninstall-rpm
299
300       # Test latest Oxygen snapshot
301       - inject:
302           properties-content: 'STREAM=oxygen'
303       - shell: !include-raw: build-rpm-snap.sh
304       - install-test-uninstall-rpm
305
306       # Test Fluorine pre-release autorelease tarball
307       # NB: This will need to be updated as old builds expire
308       - inject:
309           # yamllint disable-line rule:line-length
310           properties-content: 'DOWNLOAD_URL=https://nexus.opendaylight.org/content/repositories/autorelease-2191/org/opendaylight/integration/karaf/0.9.0/karaf-0.9.0.tar.gz'
311       - shell: !include-raw-escape: build-rpm.sh
312       - install-test-uninstall-rpm
313
314       # Test Fluorine multipatch zip (no parallel tarball available)
315       # NB: This will need to be updated as old builds expire
316       - inject:
317           # yamllint disable-line rule:line-length
318           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-20180531.192226-59.zip'
319       - shell: !include-raw-escape: build-rpm.sh
320       - install-test-uninstall-rpm
321
322       # Test latest Fluorine snapshot
323       - inject:
324           properties-content: 'STREAM=fluorine'
325       - shell: !include-raw: build-rpm-snap.sh
326       - install-test-uninstall-rpm
327
328     triggers:
329       - timed: '@daily'
330       - gerrit:
331           server-name: '{gerrit-server-name}'
332           trigger-on:
333             - comment-added-contains-event:
334                 comment-contains-value: 'verify-rpm-full'
335           projects:
336             - project-compare-type: ANT
337               project-pattern: '{project}'
338               branches:
339                 - branch-compare-type: ANT
340                   branch-pattern: '**/{branch}'
341
342     publishers:
343       - lf-infra-publish
344
345
346 - job-template:
347     name: 'packaging-test-rpm-master'
348
349     node: centos7-builder-2c-8g
350
351     parameters:
352       - opendaylight-infra-parameters:
353           os-cloud: '{os-cloud}'
354           project: '{project}'
355           branch: '{branch}'
356           refspec: 'refs/heads/{branch}'
357           artifacts: '{archive-artifacts}'
358       - string:
359           name: URL
360           # yamllint disable-line rule:line-length
361           default: 'https://git.opendaylight.org/gerrit/gitweb?p=integration/packaging.git;a=blob_plain;f=packages/rpm/example_repo_configs/opendaylight-8-devel.repo'
362           description: 'Link to .repo or .rpm file'
363
364     scm:
365       - integration-gerrit-scm:
366           basedir: 'packaging'
367           refspec: '$GERRIT_REFSPEC'
368           branch: 'master'
369
370     wrappers:
371       - opendaylight-infra-wrappers:
372           build-timeout: '{build-timeout}'
373
374     builders:
375       - shell: |
376           # Install expect to interact with Karaf shell
377           # Install nmap to check status of ODL's SSH port
378           sudo yum install -y expect nmap
379       - shell: !include-raw-escape: install-rpm.sh
380       - shell: !include-raw: start-odl.sh
381       - shell: !include-raw-escape: test-ports-nofeature.sh
382       - shell: !include-raw: test-karaf-oxygensafe.expect
383       # Disable this test until ODLPARENT-139 is fixed
384       # - shell: !include-raw-escape: test-rest-ok.sh
385       - shell: !include-raw: stop-odl.sh
386       - shell: !include-raw: uninstall-rpm.sh
387
388     publishers:
389       # TODO: Remove the archive publisher
390       #       small data should be stored on logs.opendaylight.org
391       #       large data should be stored on nexus.opendaylight.org
392       - archive:
393           artifacts: '**'
394           allow-empty: true
395           fingerprint: true
396           latest-only: true
397       - lf-infra-publish
398
399
400 - job-template:
401     name: 'packaging-test-rpm-upgrade-master'
402
403     node: centos7-builder-2c-8g
404
405     parameters:
406       - opendaylight-infra-parameters:
407           os-cloud: '{os-cloud}'
408           project: '{project}'
409           branch: '{branch}'
410           refspec: 'refs/heads/{branch}'
411           artifacts: '{archive-artifacts}'
412       - string:
413           name: URL
414           # yamllint disable-line rule:line-length
415           default: 'https://raw.githubusercontent.com/opendaylight/integration-packaging/master/packages/rpm/example_repo_configs/opendaylight-7-release.repo'
416           description: 'Link to .repo or .rpm file'
417       - string:
418           name: UPGRADE_URL
419           # yamllint disable-line rule:line-length
420           default: 'https://raw.githubusercontent.com/opendaylight/integration-packaging/master/packages/rpm/example_repo_configs/opendaylight-7-devel.repo'
421           description: 'Link to .repo or .rpm file'
422
423     scm:
424       - integration-gerrit-scm:
425           basedir: 'packaging'
426           refspec: '$GERRIT_REFSPEC'
427           branch: 'master'
428
429     wrappers:
430       - opendaylight-infra-wrappers:
431           build-timeout: '{build-timeout}'
432
433     builders:
434       - shell: !include-raw-escape: install-rpm.sh
435       - shell: !include-raw: start-odl.sh
436       - shell: |
437           # Install expect to interact with Karaf shell
438           sudo yum install -y expect
439           # Install nmap to check status of ODL's SSH port
440           sudo yum install -y nmap
441       - shell: !include-raw: test-karaf-oxygensafe.expect
442       - shell: !include-raw: stop-odl.sh
443       - shell: !include-raw: test-rpm-upgrade.sh
444       - shell: !include-raw: start-odl.sh
445       - shell: !include-raw: test-karaf-oxygensafe.expect
446       - shell: !include-raw: stop-odl.sh
447       - shell: !include-raw: uninstall-rpm.sh
448
449     publishers:
450       - lf-infra-publish
451
452
453 - job-template:
454     name: 'packaging-test-deb-master'
455
456     node: ubuntu1604-mininet-ovs-25-1c-4g
457
458     parameters:
459       - opendaylight-infra-parameters:
460           os-cloud: '{os-cloud}'
461           project: '{project}'
462           branch: '{branch}'
463           refspec: 'refs/heads/{branch}'
464           artifacts: '{archive-artifacts}'
465       - string:
466           name: PACKAGE
467           default: 'ppa:odl-team/oxygen'
468           description: 'Link to .deb package or name of PPA repo'
469
470     scm:
471       - integration-gerrit-scm:
472           basedir: 'packaging'
473           refspec: '$GERRIT_REFSPEC'
474           branch: 'master'
475
476     wrappers:
477       - opendaylight-infra-wrappers:
478           build-timeout: '{build-timeout}'
479
480     builders:
481       - shell: !include-raw-escape: install-deb.sh
482       - shell: !include-raw: start-odl.sh
483       - shell: !include-raw-escape: test-ports-nofeature.sh
484       - shell: |
485           # Install expect to interact with Karaf shell
486           # Install nmap to check status of ODL's SSH port
487           sudo apt-get install -y expect nmap
488       - shell: !include-raw: test-karaf-oxygensafe.expect
489       # Disable this test until ODLPARENT-139 is fixed
490       # - shell: !include-raw-escape: test-rest-ok.sh
491       - shell: !include-raw: stop-odl.sh
492       - shell: !include-raw-escape: uninstall-deb.sh
493
494     publishers:
495       - lf-infra-publish
496
497
498 - job-template:
499     name: 'packaging-build-deb-{stream}'
500
501     node: ubuntu1604-mininet-ovs-25-1c-4g
502
503     project-type: freestyle
504
505     mvn-opts: ''
506     mvn-params: ''
507     mvn-version: mvn33
508
509     properties:
510       - opendaylight-infra-properties:
511           build-days-to-keep: 7
512
513     parameters:
514       - opendaylight-infra-parameters:
515           os-cloud: '{os-cloud}'
516           project: '{project}'
517           branch: '{branch}'
518           refspec: 'refs/heads/{branch}'
519           artifacts: '{archive-artifacts}'
520       - lf-infra-maven-parameters:
521           mvn-opts: '{mvn-opts}'
522           mvn-params: '{mvn-params}'
523           mvn-version: '{mvn-version}'
524           staging-profile-id: ''
525       - string:
526           name: DOWNLOAD_URL
527           # FIXME: Update the default value to an active stream.
528           # yamllint disable-line rule:line-length
529           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'
530           description: 'URL to ODL tarball artifact to repackage into .deb'
531       - string:
532           name: CHANGELOG_NAME
533           default: 'Jenkins'
534           description: 'Name of person who defined .deb'
535       - string:
536           name: CHANGELOG_EMAIL
537           default: 'jenkins-donotreply@opendaylight.org'
538           description: 'Email of person who defined .deb'
539
540     scm:
541       - integration-gerrit-scm:
542           basedir: 'packaging'
543           refspec: '$GERRIT_REFSPEC'
544           branch: 'master'
545
546     wrappers:
547       - opendaylight-infra-wrappers:
548           build-timeout: '{build-timeout}'
549
550     builders:
551       - shell: !include-raw: build-deb.sh
552       - install-test-uninstall-deb
553       - lf-infra-deploy-maven-file:
554           global-settings-file: 'global-settings'
555           settings-file: 'packaging-settings'
556           mvn-version: '{mvn-version}'
557           repo-id: 'opendaylight-{stream}-ubuntu-1604-x86_64-devel'
558           group-id: '{group-id}'
559           upload-files-dir: '{upload-files-dir}'
560           maven-repo-url: '{maven-repo-url}'
561
562     publishers:
563       - lf-infra-publish