2d7ee76ec7e999ad325619ac1842cf06f1f5f052
[releng/builder.git] / jjb / netvirt / netvirt.yaml
1 # REMOVE THIS LINE IF YOU WANT TO CUSTOMIZE ANYTHING BELOW
2 # Otherwise this file will be automatically overwritten by the template
3 # autobuilder.
4
5 # ODL Releng build templates
6 - project:
7     name: netvirt
8     jobs:
9         - 'netvirt-verify-{stream}'
10         - 'netvirt-merge-{stream}'
11         - 'netvirt-periodic-{stream}'
12         - 'netvirt-distribution-{stream}'
13         - 'netvirt-distribution-check-{stream}'
14         - 'netvirt-integration-{stream}'
15         - 'netvirt-clm-{stream}'
16         - 'netvirt-validate-autorelease-{stream}'
17
18
19     # stream:    release stream (eg. stable-lithium or beryllium)
20     # branch:    git branch (eg. stable/lithium or master)
21     stream:
22         - boron:
23             branch: 'master'
24             jdk: openjdk8
25             jdks:
26                 - openjdk8
27             disable_autorelease: False
28             disable_distribution_check: False
29         - beryllium:
30             branch: 'stable/beryllium'
31             jdk: openjdk7
32             jdks:
33                 - openjdk7
34                 - openjdk8
35             disable_autorelease: False
36             disable_distribution_check: False
37
38     project: 'netvirt'
39
40 # For the Job templates below replace instances of:
41 # PROJECT_SHORTNAME with your project name (eg. circuitsw)
42 # PROJECT_PATH with your project name (eg. ofextensions/circuitsw)
43 # MAVEN_GOALS with your maven goals to build
44 # MAVEN_OPTS with your maven options to build
45
46 - job-template:
47     name: 'netvirt-verify-{stream}'
48
49     # Job template for ODL verify jobs
50     #
51     # The purpose of this job template is to setup a ODL verify job
52     #
53     # Required Variables:
54     #     stream:    release stream (eg. stable-lithium or beryllium)
55     #     branch:    git branch (eg. stable/lithium or master)
56
57     project-type: matrix
58     node: matrix_master
59     concurrent: true
60
61     axes:
62         - axis:
63             type: slave
64             name: nodes
65             values:
66                 - dynamic_verify
67         - axis:
68             type: jdk
69             values: '{obj:jdks}'
70
71     logrotate:
72         daysToKeep: '{build-days-to-keep}'
73         numToKeep: '{build-num-to-keep}'
74         artifactDaysToKeep: '{build-artifact-days-to-keep}'
75         artifactNumToKeep: '{build-artifact-num-to-keep}'
76
77     parameters:
78         - project-parameter:
79             project: '{project}'
80         - gerrit-parameters:
81             project: '{project}'
82             branch: '{branch}'
83             refspec: 'refs/heads/{branch}'
84
85     scm:
86         - gerrit-trigger-scm:
87             credentials-id: '{ssh-credentials}'
88             refspec: '$GERRIT_REFSPEC'
89             choosing-strategy: 'gerrit'
90
91     wrappers:
92         - build-timeout
93         - ssh-agent-credentials:
94             users:
95                 - '{ssh-credentials}'
96
97     triggers:
98         - gerrit-trigger-patch-submitted:
99             name: 'netvirt'
100             branch: '{branch}'
101
102     builders:
103         - wipe-org-opendaylight-repo
104         - jacoco-nojava-workaround
105         - provide-maven-settings:
106             global-settings-file: 'odl-global-settings'
107             settings-file: 'netvirt-settings'
108         - maven-target:
109             maven-version: '{mvn33}'
110             pom: 'pom.xml'
111             goals: 'clean install -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r  -V -B -Djenkins -Dstream={stream}'
112             java-opts:
113                 - '-Xmx1024m -XX:MaxPermSize=256m'
114             settings: 'netvirt-settings'
115             settings-type: cfp
116             global-settings: 'odl-global-settings'
117             global-settings-type: cfp
118
119     publishers:
120         - archive-artifacts:
121             artifacts: '**/target/surefire-reports/*-output.txt, '
122         - findbugs
123         - email-notification:
124             email-prefix: '[netvirt]'
125         - jacoco-report
126
127 - job-template:
128     name: 'netvirt-merge-{stream}'
129
130     # Job template for ODL merge jobs
131     #
132     # The purpose of this job template is to setup a ODL merge job
133     # and deploy artifacts to Nexus.
134     #
135     # Required Variables:
136     #     stream:    release stream (eg. stable-lithium or beryllium)
137     #     branch:    git branch (eg. stable/lithium or master)
138
139     project-type: maven
140     node: dynamic_merge
141     jdk: '{jdk}'
142
143     logrotate:
144         daysToKeep: '14'
145         numToKeep: '10'
146         artifactDaysToKeep: '{build-artifact-days-to-keep}'
147         artifactNumToKeep: '{build-artifact-num-to-keep}'
148
149     parameters:
150         - project-parameter:
151             project: '{project}'
152         - gerrit-parameters:
153             project: '{project}'
154             branch: '{branch}'
155             refspec: 'refs/heads/{branch}'
156
157     scm:
158         - gerrit-trigger-scm:
159             credentials-id: '{ssh-credentials}'
160             refspec: ''
161             choosing-strategy: 'default'
162
163     wrappers:
164         - build-timeout
165         - ssh-agent-credentials:
166             users:
167                 - '{ssh-credentials}'
168
169     triggers:
170         - timed: 'H H * * 0'
171         - gerrit-trigger-patch-merged:
172             name: 'netvirt'
173             branch: '{branch}'
174
175     prebuilders:
176         - wipe-org-opendaylight-repo
177         - jacoco-nojava-workaround
178         - provide-maven-settings:
179             global-settings-file: 'odl-global-settings'
180             settings-file: 'netvirt-settings'
181
182     maven:
183         maven-name: '{mvn33}'
184         root-pom: 'pom.xml'
185         goals: 'clean install -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r  -V -B -Djenkins -Dmerge -Dstream={stream}'
186         maven-opts: '-Xmx1024m -XX:MaxPermSize=256m'
187         settings: 'netvirt-settings'
188         settings-type: cfp
189         global-settings: 'odl-global-settings'
190         global-settings-type: cfp
191         post-step-run-condition: UNSTABLE
192
193     postbuilders:
194         - conditional-step:
195             condition-kind: file-exists
196             condition-filename: deploy-site.xml
197             condition-basedir: workspace
198
199             # The strategy here is intentional to run Maven site:deploy twice
200             # once using regular pom.xml to produce a staged-site which is
201             # then used by deploy-site.xml to push to Nexus. This is a
202             # workaround to Maven Site's default linking code which creates
203             # incorrect URLs for sites due to auto-detection assuming your
204             # project is configured in a certain way which ODL is not.
205             steps:
206             - maven-target:
207                 maven-version: '{mvn33}'
208                 pom: pom.xml
209                 goals: 'site:deploy -V -B -Dstream={stream}'
210                 java-opts:
211                     - '-Xmx2g'
212                 settings: 'netvirt-settings'
213                 settings-type: cfp
214                 global-settings: 'odl-global-settings'
215                 global-settings-type: cfp
216             - maven-target:
217                 maven-version: '{mvn33}'
218                 pom: deploy-site.xml
219                 goals: 'site:deploy -V -B -Dstream={stream}'
220                 java-opts:
221                     - '-Xmx2g'
222                 settings: 'netvirt-settings'
223                 settings-type: cfp
224                 global-settings: 'odl-global-settings'
225                 global-settings-type: cfp
226
227     reporters:
228         - findbugs
229
230     publishers:
231         - archive-artifacts:
232             artifacts: '**/target/surefire-reports/*-output.txt, '
233         - email-notification:
234             email-prefix: '[netvirt]'
235         - maven-deploy:
236             id: ''
237             unique-version: true
238             deploy-unstable: false
239         - jacoco-report
240
241 - job-template:
242     name: 'netvirt-periodic-{stream}'
243     disabled: false
244
245     # Job template for periodic builders
246     #
247     # The purpose of this job template is to setup a periodic
248     # builder.
249     #
250     # Required Variables:
251     #     stream:    release stream (eg. stable-lithium or beryllium)
252     #     branch:    git branch (eg. stable/lithium or master)
253
254     project-type: maven
255     node: dynamic_verify
256     jdk: '{jdk}'
257
258     logrotate:
259         daysToKeep: '14'
260         numToKeep: '10'
261         artifactDaysToKeep: '{build-artifact-days-to-keep}'
262         artifactNumToKeep: '{build-artifact-num-to-keep}'
263
264     parameters:
265         - project-parameter:
266             project: '{project}'
267
268     scm:
269         - git-scm:
270             credentials-id: '{ssh-credentials}'
271             refspec: ''
272             branch: '{branch}'
273
274     wrappers:
275         - build-timeout
276         - ssh-agent-credentials:
277             users:
278                 - '{ssh-credentials}'
279
280     triggers:
281         - timed: '@daily'
282
283     prebuilders:
284         - wipe-org-opendaylight-repo
285         - jacoco-nojava-workaround
286         - provide-maven-settings:
287             global-settings-file: 'odl-global-settings'
288             settings-file: 'netvirt-settings'
289
290     maven:
291         maven-name: '{mvn33}'
292         root-pom: 'pom.xml'
293         goals: 'clean install -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r  -V -B -Djenkins'
294         maven-opts: '-Xmx1024m -XX:MaxPermSize=256m'
295         settings: 'netvirt-settings'
296         settings-type: cfp
297         global-settings: 'odl-global-settings'
298         global-settings-type: cfp
299
300     reporters:
301         - findbugs
302
303     publishers:
304         - email-notification:
305             email-prefix: '[netvirt]'
306         - jacoco-report
307
308 - job-template:
309     name: 'netvirt-distribution-{stream}'
310
311     # Required variables:
312     #     stream:    release stream (eg. stable-lithium or beryllium)
313     #     branch:    git branch (eg. stable/lithium or master)
314
315     project-type: maven
316     node: dynamic_merge
317     jdk: '{jdk}'
318
319     logrotate:
320         daysToKeep: '{build-days-to-keep}'
321         numToKeep: '{build-num-to-keep}'
322         artifactDaysToKeep: '{build-artifact-days-to-keep}'
323         artifactNumToKeep: '{build-artifact-num-to-keep}'
324
325     parameters:
326         - project-parameter:
327             project: 'integration/distribution'
328
329     scm:
330         - git-scm:
331             credentials-id: '{ssh-credentials}'
332             refspec: ''
333             branch: '{branch}'
334
335     wrappers:
336         - build-timeout
337         - ssh-agent-credentials:
338             users:
339                 - '{ssh-credentials}'
340
341     triggers:
342         - reverse:
343             jobs: '{project}-merge-{stream}'
344             result: 'success'
345
346     prebuilders:
347         - wipe-org-opendaylight-repo
348         - provide-maven-settings:
349             global-settings-file: 'odl-global-settings'
350             settings-file: 'netvirt-settings'
351
352     maven:
353         maven-name: '{mvn33}'
354         root-pom: 'pom.xml'
355         goals: 'clean install -V -B -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r'
356         maven-opts: '-Xmx1024m -XX:MaxPermSize=256m -Dmaven.compile.fork=true'
357         settings: 'integration-distribution-settings'
358         settings-type: cfp
359         global-settings: 'odl-global-settings'
360         global-settings-type: cfp
361
362     publishers:
363         - email-notification:
364             email-prefix: '[{project}]'
365         - maven-deploy:
366             id: ''
367             unique-version: true
368             deploy-unstable: false
369
370 # Template: integration-patch-distribution-{stream}
371 # Goal: Build a patch and make sure the distribution can deploy with this change
372 # Operation: This job template builds a patch, creates a distribution containing
373 #            the patch, and triggers the distribution deploy test
374
375 - job-template:
376     name: 'netvirt-distribution-check-{stream}'
377     disabled: '{obj:disable_distribution_check}'
378
379     project-type: maven
380     node: dynamic_verify
381     concurrent: true
382     jdk: '{jdk}'
383
384     logrotate:
385         daysToKeep: '{build-days-to-keep}'
386         numToKeep: '{build-num-to-keep}'
387         artifactDaysToKeep: '{build-artifact-days-to-keep}'
388         artifactNumToKeep: '{build-artifact-num-to-keep}'
389
390     parameters:
391         - gerrit-parameters:
392             project: '{project}'
393             branch: '{branch}'
394             refspec: 'refs/heads/{branch}'
395         - project-parameter:
396             project: '{project}'
397         - integration-distribution-git-url
398
399     scm:
400         - integration-gerrit-scm:
401             credentials-id: '{ssh-credentials}'
402             basedir: '$GERRIT_PROJECT'
403             refspec: '$GERRIT_REFSPEC'
404             branch: '{branch}'
405         - integration-distribution-scm:
406             credentials-id: '{ssh-credentials}'
407             branch: '{branch}'
408
409     wrappers:
410         - build-timeout
411         - ssh-agent-credentials:
412             users:
413                 - '{ssh-credentials}'
414
415     triggers:
416         - gerrit:
417             server-name: 'OpenDaylight'
418             trigger-on:
419                 - patchset-created-event:
420                     exclude-drafts: 'true'
421                     exclude-trivial-rebase: 'false'
422                     exclude-no-code-change: 'true'
423                 - draft-published-event
424                 - comment-added-contains-event:
425                     comment-contains-value: 'test-distribution'
426                 - comment-added-contains-event:
427                     comment-contains-value: 'reverify'
428                 - comment-added-contains-event:
429                     comment-contains-value: 'recheck'
430             projects:
431               - project-compare-type: 'ANT'
432                 project-pattern: '{name}'
433                 branches:
434                   - branch-compare-type: 'ANT'
435                     branch-pattern: '**/{branch}'
436             skip-vote:
437                 successful: false
438                 failed: false
439                 unstable: false
440                 notbuilt: false
441
442     prebuilders:
443         - wipe-org-opendaylight-repo
444         - maven-target:
445             maven-version: '{mvn33}'
446             pom: '$GERRIT_PROJECT/pom.xml'
447             goals: 'clean install -V -B -Djenkins -DskipTests -Dcheckstyle.skip=true -Dmaven.javadoc.skip=true -Dmaven.site.skip=true -DgenerateReports=false -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Dstream={stream}'
448             java-opts:
449                 - '-Xmx4096m -XX:MaxPermSize=1024m -Dmaven.compile.fork=true'
450             settings: 'netvirt-settings'
451             settings-type: cfp
452             global-settings: 'odl-global-settings'
453             global-settings-type: cfp
454
455     maven:
456         maven-name: '{mvn33}'
457         root-pom: 'distribution/pom.xml'
458         goals: 'clean install -V -B -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r'
459         maven-opts: '-Xmx1024m -XX:MaxPermSize=256m -Dmaven.compile.fork=true'
460         settings: 'netvirt-settings'
461         settings-type: cfp
462         global-settings: 'odl-global-settings'
463         global-settings-type: cfp
464         ignore-upstream-changes: true
465         post-step-run-condition: 'SUCCESS'
466
467     postbuilders:
468         - integration-distribution-check
469
470     publishers:
471         - archive:
472             artifacts: 'karaf.log'
473         - archive:
474             artifacts: 'karaf_console.log'
475         - email-notification:
476             email-prefix: '[netvirt]'
477
478 - job-template:
479     name: 'netvirt-integration-{stream}'
480     disabled: false
481
482     # Job template for ODL integration verify jobs
483     #
484     # This is similar to a normal verify job, but it runs
485     # when a project that's a dependency of your project
486     # is successfully built.
487     #
488     # Required Variables:
489     #     stream:    release stream (eg. stable-lithium or beryllium)
490     #     branch:    git branch (eg. stable/lithium or master)
491
492     project-type: maven
493     node: dynamic_merge
494     jdk: '{jdk}'
495
496     logrotate:
497         daysToKeep: '{build-days-to-keep}'
498         numToKeep: '{build-num-to-keep}'
499         artifactDaysToKeep: '{build-artifact-days-to-keep}'
500         artifactNumToKeep: '{build-artifact-num-to-keep}'
501
502     parameters:
503         - project-parameter:
504             project: '{project}'
505
506     scm:
507         - git-scm:
508             credentials-id: '{ssh-credentials}'
509             refspec: ''
510             branch: '{branch}'
511
512     wrappers:
513         - build-timeout
514         - ssh-agent-credentials:
515             users:
516                 - '{ssh-credentials}'
517
518     triggers:
519         - reverse:
520             jobs: 'controller-merge-{stream},neutron-merge-{stream},odlparent-merge-{stream},openflowjava-merge-{stream},openflowplugin-merge-{stream},ovsdb-merge-{stream},sfc-merge-{stream},yangtools-merge-{stream}'
521             result: 'success'
522
523     prebuilders:
524         - wipe-org-opendaylight-repo
525         - jacoco-nojava-workaround
526         - provide-maven-settings:
527             global-settings-file: 'odl-global-settings'
528             settings-file: 'netvirt-settings'
529
530     maven:
531         maven-name: '{mvn33}'
532         root-pom: 'pom.xml'
533         goals: 'clean install -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r  -V -B -Djenkins'
534         maven-opts: '-Xmx1024m -XX:MaxPermSize=256m'
535         settings: 'netvirt-settings'
536         settings-type: cfp
537         global-settings: 'odl-global-settings'
538         global-settings-type: cfp
539
540     reporters:
541         - findbugs
542
543     publishers:
544         - email-notification:
545             email-prefix: '[netvirt] [controller] [neutron] [odlparent] [openflowjava] [openflowplugin] [ovsdb] [sfc] [yangtools]'
546         - jacoco-report
547
548 - job-template:
549     name: 'netvirt-clm-{stream}'
550     disabled: false
551
552     project-type: maven
553     node: dynamic_verify
554     jdk: '{jdk}'
555
556     logrotate:
557         daysToKeep: '{build-days-to-keep}'
558         numToKeep: '{build-num-to-keep}'
559         artifactDaysToKeep: '{build-artifact-days-to-keep}'
560         artifactNumToKeep: '{build-artifact-num-to-keep}'
561
562     parameters:
563         - project-parameter:
564             project: '{project}'
565
566     scm:
567         - git-scm:
568             credentials-id: '{ssh-credentials}'
569             refspec: ''
570             branch: '{branch}'
571
572     wrappers:
573         - build-timeout
574         - ssh-agent-credentials:
575             users:
576                 - '{ssh-credentials}'
577
578     triggers:
579         - timed: 'H H * * 6'
580
581     prebuilders:
582         - wipe-org-opendaylight-repo
583         - provide-maven-settings:
584             global-settings-file: 'odl-global-settings'
585             settings-file: 'netvirt-settings'
586
587     maven:
588         maven-name: '{mvn33}'
589         root-pom: 'pom.xml'
590         goals: 'clean install com.sonatype.clm:clm-maven-plugin:index -V -B -Djenkins -DskipTests=true -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r'
591         maven-opts: '-Xmx4096m -XX:MaxPermSize=512m'
592         settings: 'netvirt-settings'
593         settings-type: cfp
594         global-settings: 'odl-global-settings'
595         global-settings-type: cfp
596
597     postbuilders:
598         - shell: 'find . -regex ".*karaf/target" | xargs rm -rf'
599         - check-clm:
600             application-name: netvirt
601
602     publishers:
603         - email-notification:
604             email-prefix: '[netvirt]'
605
606 - job-template:
607     name: 'netvirt-validate-autorelease-{stream}'
608     disabled: '{obj:disable_autorelease}'
609
610     project-type: maven
611     node: dynamic_verify
612     concurrent: true
613     jdk: '{jdk}'
614
615     logrotate:
616         daysToKeep: '{build-days-to-keep}'
617         numToKeep: '{build-num-to-keep}'
618         artifactDaysToKeep: '{build-artifact-days-to-keep}'
619         artifactNumToKeep: '{build-artifact-num-to-keep}'
620
621     parameters:
622         - project-parameter:
623             project: '{project}'
624         - gerrit-parameters:
625             project: '{project}'
626             branch: '{branch}'
627             refspec: 'refs/heads/{branch}'
628         - autorelease-release-tag:
629             release-tag: 'validate'
630         - autorelease-release-branch:
631             release-branch: '{branch}'
632         - string:
633             name: CLONE_URL
634             default: 'ssh://jenkins-$SILO@git.opendaylight.org:29418/releng/autorelease'
635             description: "Autorelease clone URL"
636
637     scm:
638         - git:
639             url: '$CLONE_URL'
640             credentials-id: '{ssh-credentials}'
641             refspec: ''
642             branches:
643                 - 'origin/{branch}'
644             skip-tag: true
645             submodule:
646                 recursive: true
647                 timeout: 60
648
649     wrappers:
650         - autorelease-build-timeout
651         - ssh-agent-credentials:
652             users:
653                 - '{ssh-credentials}'
654
655     triggers:
656         - gerrit:
657             server-name: 'OpenDaylight'
658             trigger-on:
659                 - patchset-created-event:
660                     exclude-drafts: 'true'
661                     exclude-trivial-rebase: 'false'
662                     exclude-no-code-change: 'true'
663                 - draft-published-event
664                 - comment-added-contains-event:
665                     comment-contains-value: 'recheck'
666                 - comment-added-contains-event:
667                     comment-contains-value: 'reverify'
668                 - comment-added-contains-event:
669                     comment-contains-value: 'revalidate'
670             projects:
671               - project-compare-type: 'ANT'
672                 project-pattern: 'netvirt'
673                 branches:
674                   - branch-compare-type: 'ANT'
675                     branch-pattern: '**/{branch}'
676                 file-paths:
677                     - compare-type: ANT
678                       pattern: '**/*.xml'
679
680     prebuilders:
681         - wipe-org-opendaylight-repo
682         - jacoco-nojava-workaround
683         - autorelease-checkout-gerrit-patch
684         - autorelease-generate-release-patches
685         - maven-target:
686             maven-version: '{mvn33}'
687             pom: validate-pom.xml
688             goals: 'clean install -V -B -T1.5C -Djenkins -DskipTests -Dcheckstyle.skip=true -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r'
689             java-opts:
690             - '-Xmx8g'
691             settings: 'autorelease-settings'
692             settings-type: cfp
693             global-settings: 'odl-global-settings'
694             global-settings-type: cfp
695
696     maven:
697         maven-name: '{mvn33}'
698         root-pom: 'pom.xml'
699         goals: 'clean validate -V -B -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r'
700         maven-opts: '-Xmx8g -XX:MaxPermSize=1024m -Dmaven.compile.fork=true'
701         settings: 'autorelease-settings'
702         settings-type: cfp
703         global-settings: 'odl-global-settings'
704         global-settings-type: cfp
705         automatic-archiving: false
706         post-step-run-condition: UNSTABLE
707
708     postbuilders:
709         - autorelease-sys-stats
710
711     publishers:
712         - email-notification:
713             email-prefix: '[autorelease] [netvirt]'
714