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