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