hc2vpp.yaml revision 63a83ad1
1- project:
2    name: hc2vpp
3    jobs:
4        - 'hc2vpp-verify-{stream}-{os}'
5        - 'hc2vpp-merge-{stream}-{os}'
6        - 'hc2vpp-integration-{stream}-{os}'
7        - 'hc2vpp-verify-image-{stream}-{os}'
8    project: 'hc2vpp'
9    os:
10        - ubuntu1404:
11            repo-os-part: 'ubuntu.trusty.main'
12            skip-site: 'false'
13        - ubuntu1604:
14            repo-os-part: 'ubuntu.xenial.main'
15            skip-site: 'true'
16        - centos7:
17            repo-os-part: 'centos7'
18            skip-site: 'true'
19    stream:
20        - master:
21            branch: 'master'
22            repo-stream-part: 'master'
23        - '1701':
24            branch: 'stable/1701'
25            repo-stream-part: 'stable.1701'
26
27- job-template:
28    name: 'hc2vpp-verify-{stream}-{os}'
29    project-type: maven
30    node: '{os}-basebuild-4c-4g'
31    concurrent: true
32    jdk: openjdk8-{os}
33
34    logrotate:
35        daysToKeep: '{build-days-to-keep}'
36        numToKeep: '{build-num-to-keep}'
37        artifactDaysToKeep: '{build-artifact-days-to-keep}'
38        artifactNumToKeep: '{build-artifact-num-to-keep}'
39
40    parameters:
41        - project-parameter:
42            project: '{project}'
43        - gerrit-parameter:
44            branch: '{branch}'
45        - os-parameter:
46            os: '{os}'
47
48    scm:
49        - gerrit-trigger-scm:
50            credentials-id: 'jenkins-gerrit-credentials'
51            refspec: '$GERRIT_REFSPEC'
52            choosing-strategy: 'gerrit'
53
54    wrappers:
55        - fdio-infra-wrappers:
56            build-timeout: '{build-timeout}'
57
58    triggers:
59        - gerrit-trigger-patch-submitted:
60            name: 'hc2vpp'
61            branch: '{branch}'
62
63    prebuilders:
64        - shell: |
65            if [ "${{OS}}" == "ubuntu1404" ];then sudo update-java-alternatives -s /usr/lib/jvm/java-1.8.0-openjdk-amd64||echo 'ignoring failure';fi
66    maven:
67        maven-name: 'mvn33-new'
68        root-pom: 'pom.xml'
69        goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r  -Dmerge site'
70        maven-opts: '-Xmx2048m -Dmaven.compile.fork=true'
71        settings: 'hc2vpp-settings'
72        settings-type: cfp
73        global-settings: 'global-settings'
74        global-settings-type: cfp
75
76    publishers:
77        - email-notification:
78            email-prefix: '[hc2vpp]'
79        - fdio-infra-shiplogs:
80            maven-version: 'mvn33-new'
81
82- job-template:
83    name: 'hc2vpp-verify-image-{stream}-{os}'
84    project-type: maven
85    node: '{os}-basebuild-4c-4g'
86    concurrent: true
87    jdk: openjdk8-{os}
88
89    logrotate:
90        daysToKeep: '{build-days-to-keep}'
91        numToKeep: '{build-num-to-keep}'
92        artifactDaysToKeep: '{build-artifact-days-to-keep}'
93        artifactNumToKeep: '{build-artifact-num-to-keep}'
94
95    parameters:
96        - project-parameter:
97            project: '{project}'
98        - gerrit-parameter:
99            branch: '{branch}'
100        - os-parameter:
101            os: '{os}'
102
103    scm:
104        - gerrit-trigger-scm:
105            credentials-id: 'jenkins-gerrit-credentials'
106            refspec: '$GERRIT_REFSPEC'
107            choosing-strategy: 'gerrit'
108
109    wrappers:
110        - fdio-infra-wrappers:
111            build-timeout: '{build-timeout}'
112
113    triggers:
114        - gerrit:
115            server-name: 'Primary'
116            trigger-on:
117                - comment-added-contains-event:
118                    comment-contains-value: 'verify-images'
119            projects:
120              - project-compare-type: 'ANT'
121                project-pattern: '{project}'
122                branches:
123                  - branch-compare-type: 'ANT'
124                    branch-pattern: '**/{branch}'
125            skip-vote:
126                successful: true
127                failed: true
128                unstable: true
129                notbuilt: true
130
131    prebuilders:
132        - shell: |
133            if [ "${{OS}}" == "ubuntu1404" ];then sudo update-java-alternatives -s /usr/lib/jvm/java-1.8.0-openjdk-amd64||echo 'ignoring failure';fi
134    maven:
135        maven-name: 'mvn33-new'
136        root-pom: 'pom.xml'
137        goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r  -Dmerge'
138        maven-opts: '-Xmx2048m -Dmaven.compile.fork=true'
139        settings: 'hc2vpp-settings'
140        settings-type: cfp
141        global-settings: 'global-settings'
142        global-settings-type: cfp
143
144    publishers:
145        - email-notification:
146            email-prefix: '[hc2vpp]'
147        - fdio-infra-shiplogs:
148            maven-version: 'mvn33-new'
149
150- job-template:
151    name: 'hc2vpp-merge-{stream}-{os}'
152    project-type: maven
153    node: '{os}-basebuild-4c-4g'
154    jdk: openjdk8-{os}
155
156    logrotate:
157        daysToKeep: '{build-days-to-keep}'
158        numToKeep: '{build-num-to-keep}'
159        artifactDaysToKeep: '{build-artifact-days-to-keep}'
160        artifactNumToKeep: '{build-artifact-num-to-keep}'
161
162    parameters:
163        - project-parameter:
164            project: '{project}'
165        - os-parameter:
166            os: '{os}'
167        - maven-project-parameter:
168            maven: 'mvn33-new'
169        - maven-exec:
170            maven-version: 'mvn33-new'
171        - repo-name-parameter:
172            repo-name: '{repo-stream-part}.{repo-os-part}'
173
174    scm:
175        - gerrit-trigger-scm:
176            credentials-id: 'jenkins-gerrit-credentials'
177            refspec: ''
178            choosing-strategy: 'default'
179
180    wrappers:
181        - ssh-agent-credentials:
182            users:
183                - 'jenkins-gerrit-credentials'
184        - fdio-infra-wrappers:
185            build-timeout: '{build-timeout}'
186
187    triggers:
188        - gerrit-trigger-patch-merged:
189            name: 'hc2vpp'
190            branch: '{branch}'
191
192    maven:
193        maven-name: 'mvn33-new'
194        root-pom: 'pom.xml'
195        goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r  -Dmerge -Dsonar -Ddocs.hc.folder=io/fd/hc2vpp -Dmaven.site.skip={skip-site} site -Dmaven.site.deploy.skip={skip-site} site:deploy'
196        maven-opts: '-Xmx2048m -Dmaven.compile.fork=true'
197        settings: 'hc2vpp-settings'
198        settings-type: cfp
199        global-settings: 'global-settings'
200        global-settings-type: cfp
201
202    reporters:
203        - findbugs
204
205    publishers:
206        - sonar:
207            jdk: 'openjdk8-{os}'
208            language: 'java'
209            branch: '{stream}'
210        - email-notification:
211            email-prefix: '[hc2vpp]'
212        - fdio-infra-shiplogs:
213            maven-version: 'mvn33-new'
214
215- job-template:
216    name: 'hc2vpp-integration-{stream}-{os}'
217    project-type: maven
218    node: '{os}-basebuild-4c-4g'
219    jdk: openjdk8-{os}
220
221    logrotate:
222        daysToKeep: '{build-days-to-keep}'
223        numToKeep: '{build-num-to-keep}'
224        artifactDaysToKeep: '{build-artifact-days-to-keep}'
225        artifactNumToKeep: '{build-artifact-num-to-keep}'
226
227    parameters:
228        - project-parameter:
229            project: '{project}'
230        - os-parameter:
231            os: '{os}'
232        - maven-project-parameter:
233            maven: 'mvn33-new'
234        - maven-exec:
235            maven-version: 'mvn33-new'
236
237        - repo-name-parameter:
238            repo-name: '{repo-stream-part}.{repo-os-part}'
239
240    scm:
241        - git-scm:
242            credentials-id: 'jenkins-gerrit-credentials'
243            refspec: ''
244            branch: '{branch}'
245
246    wrappers:
247        - ssh-agent-credentials:
248            users:
249                - 'jenkins-gerrit-credentials'
250        - fdio-infra-wrappers:
251            build-timeout: '{build-timeout}'
252
253    triggers:
254        - reverse:
255            jobs: 'vpp-merge-{stream}-{os},hc2vpp-merge-{stream}-{os}'
256            result: 'success'
257
258    prebuilders:
259        - shell: |
260            if [ "${{OS}}" == "ubuntu1404" ];then sudo update-java-alternatives -s /usr/lib/jvm/java-1.8.0-openjdk-amd64||echo 'ignoring failure';fi
261        - shell:
262            !include-raw-escape: include-raw-hc2vpp-integration-prebuild.sh
263    maven:
264        maven-name: 'mvn33-new'
265        root-pom: 'pom.xml'
266        goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r  -Dmerge'
267        maven-opts: '-Xmx2048m -Dmaven.compile.fork=true'
268        settings: 'hc2vpp-settings'
269        settings-type: cfp
270        global-settings: 'global-settings'
271        global-settings-type: cfp
272
273    postbuilders:
274        - maven-target:
275            maven-version: 'mvn33-new'
276            goals: '--version'
277            settings: 'hc2vpp-settings'
278            settings-type: cfp
279            global-settings: 'global-settings'
280            global-settings-type: cfp
281        - provide-maven-settings:
282            settings-file: 'hc2vpp-settings'
283            global-settings-file: 'global-settings'
284        - shell:
285            !include-raw-escape:
286                - ../scripts/maven_push_functions.sh
287                - include-raw-hc2vpp-pkg-push.sh
288    reporters:
289        - findbugs
290
291    publishers:
292        - email-notification:
293            email-prefix: '[hc2vpp]'
294        - maven-deploy:
295            id: ''
296            unique-version: true
297            deploy-unstable: false
298        - fdio-infra-shiplogs:
299            maven-version: 'mvn33-new'
300