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