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