Sweetcomb - run test only for ubuntu 1604
[ci-management.git] / jjb / sweetcomb / sweetcomb.yaml
1 ---
2 #########################################################################
3 #
4 # Copyright (c) 2018 Intel and/or its affiliates.
5 # Licensed under the Apache License, Version 2.0 (the "License");
6 # you may not use this file except in compliance with the License.
7 # You may obtain a copy of the License at:
8 #
9 #     http://www.apache.org/licenses/LICENSE-2.0
10 #
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an "AS IS" BASIS,
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 # See the License for the specific language governing permissions and
15 # limitations under the License.
16 #########################################################################
17
18 - project:
19     name: sweetcomb
20     jobs:
21       - 'sweetcomb-verify-{stream}-{os}'
22       - 'sweetcomb-merge-{stream}-{os}'
23       - 'sweetcomb-test-{stream}-ubuntu1604'
24
25     project: 'sweetcomb'
26     os:
27       - ubuntu1604:
28           repo-os-part: 'ubuntu.xenial.main'
29       - centos7:
30           repo-os-part: 'centos7'
31     stream:
32       - master:
33           branch: 'master'
34           repo-stream-part: 'master'
35       - '1904':
36           branch: 'stable/1904'
37           repo-stream-part: 'stable.1904'
38       - '1901':
39           branch: 'stable/1901'
40           repo-stream-part: 'stable.1901'
41
42 - project:
43     name: sweetcomb-view
44     views:
45       - project-view
46     project-name: sweetcomb
47
48 - job-template:
49     name: 'sweetcomb-verify-{stream}-{os}'
50
51     project-type: freestyle
52     node: '{os}-us'
53     concurrent: true
54
55     build-discarder:
56       daysToKeep: '{build-days-to-keep}'
57       numToKeep: 100
58       artifactDaysToKeep: '{build-artifact-days-to-keep}'
59       artifactNumToKeep: '{build-artifact-num-to-keep}'
60
61     parameters:
62       - project-parameter:
63           project: '{project}'
64       - gerrit-parameter:
65           branch: '{branch}'
66       - os-parameter:
67           os: '{os}'
68       - repo-name-parameter:
69           repo-name: '{repo-stream-part}.{repo-os-part}'
70       - stream-parameter:
71           stream: '{stream}'
72
73     scm:
74       - gerrit-trigger-scm:
75           credentials-id: 'jenkins-gerrit-credentials'
76           refspec: '$GERRIT_REFSPEC'
77           choosing-strategy: 'gerrit'
78
79     wrappers:
80       - fdio-infra-wrappers:
81           build-timeout: 120
82
83     triggers:
84       - gerrit-trigger-checkstyle:
85           name: '{project}'
86           branch: '{branch}'
87       - gerrit-trigger-patch-submitted:
88           name: '{project}'
89           branch: '{branch}'
90
91     builders:
92       - config-file-provider:
93           files:
94             - file-id: '.packagecloud'
95               target: '/root'
96       - config-file-provider:
97           files:
98             - file-id: 'packagecloud_api'
99               target: '/root'
100       - shell:
101           !include-raw-escape: include-raw-sweetcomb-checkstyle.sh
102       - shell:
103           !include-raw-escape:
104           - include-raw-sweetcomb-build.sh
105     publishers:
106       - archive:
107           artifacts: >
108             **/build-root/build-package/*.rpm,
109             **/build-root/build-package/*.deb,
110           allow-empty: 'true'
111           fingerprint: false
112           only-if-success: true
113           default-excludes: false
114       - fdio-infra-shiplogs:
115           maven-version: 'mvn33-new'
116       - naginator:
117           rerun-unstable-builds: false
118           max-failed-builds: 1
119           fixed-delay: 90
120
121     publishers:
122       - fdio-infra-shiplogs:
123           maven-version: 'mvn33-new'
124
125 - job-template:
126     name: 'sweetcomb-merge-{stream}-{os}'
127
128     project-type: freestyle
129     node: '{os}-us'
130
131     build-discarder:
132       daysToKeep: '{build-days-to-keep}'
133       numToKeep: 100
134       artifactDaysToKeep: '{build-artifact-days-to-keep}'
135       artifactNumToKeep: '{build-artifact-num-to-keep}'
136
137     parameters:
138       - project-parameter:
139           project: '{project}'
140       - gerrit-parameter:
141           branch: '{branch}'
142       - os-parameter:
143           os: '{os}'
144       - stream-parameter:
145           stream: '{stream}'
146       - repo-name-parameter:
147           repo-name: '{repo-stream-part}.{repo-os-part}'
148
149     scm:
150       - gerrit-trigger-scm:
151           credentials-id: 'jenkins-gerrit-credentials'
152           refspec: ''
153           choosing-strategy: 'default'
154
155     wrappers:
156       - fdio-infra-wrappers:
157           build-timeout: '{build-timeout}'
158
159     triggers:
160       - gerrit-trigger-patch-merged:
161           name: '{project}'
162           branch: '{branch}'
163
164     builders:
165       - config-file-provider:
166           files:
167             - file-id: '.packagecloud'
168               target: '/root'
169       - config-file-provider:
170           files:
171             - file-id: 'packagecloud_api'
172               target: '/root'
173       - shell:
174           !include-raw-escape: include-raw-sweetcomb-checkstyle.sh
175       - shell:
176           !include-raw-escape:
177           - include-raw-sweetcomb-build.sh
178       - shell:
179           !include-raw-escape:
180           - ../scripts/packagecloud_push.sh
181     publishers:
182       - archive:
183           artifacts: >
184             **/build-root/build-package/*.rpm,
185             **/build-root/build-package/*.deb,
186           allow-empty: 'true'
187           fingerprint: false
188           only-if-success: true
189           default-excludes: false
190       - fdio-infra-shiplogs:
191           maven-version: 'mvn33-new'
192       - naginator:
193           rerun-unstable-builds: false
194           max-failed-builds: 1
195           fixed-delay: 90
196
197 - job-template:
198     name: 'sweetcomb-test-{stream}-ubuntu1604'
199
200     project-type: freestyle
201     node: 'ubuntu1604-us'
202     concurrent: true
203
204     build-discarder:
205       daysToKeep: '{build-days-to-keep}'
206       numToKeep: 100
207       artifactDaysToKeep: '{build-artifact-days-to-keep}'
208       artifactNumToKeep: '{build-artifact-num-to-keep}'
209
210     parameters:
211       - project-parameter:
212           project: '{project}'
213       - gerrit-parameter:
214           branch: '{branch}'
215       - os-parameter:
216           os: 'ubuntu1604'
217       - repo-name-parameter:
218           repo-name: '{repo-stream-part}.ubuntu.xenial.main'
219       - stream-parameter:
220           stream: '{stream}'
221
222     scm:
223       - gerrit-trigger-scm:
224           credentials-id: 'jenkins-gerrit-credentials'
225           refspec: '$GERRIT_REFSPEC'
226           choosing-strategy: 'gerrit'
227
228     wrappers:
229       - fdio-infra-wrappers:
230           build-timeout: 120
231
232     triggers:
233       - gerrit-trigger-patch-submitted:
234           name: '{project}'
235           branch: '{branch}'
236
237     builders:
238       - config-file-provider:
239           files:
240             - file-id: '.packagecloud'
241               target: '/root'
242       - config-file-provider:
243           files:
244             - file-id: 'packagecloud_api'
245               target: '/root'
246       - shell:
247           !include-raw-escape:
248           - include-raw-sweetcomb-build.sh
249           - include-raw-sweetcomb-test.sh
250     publishers:
251       - archive:
252           allow-empty: 'true'
253           fingerprint: false
254           only-if-success: true
255           default-excludes: false
256       - fdio-infra-shiplogs:
257           maven-version: 'mvn33-new'
258       - naginator:
259           rerun-unstable-builds: false
260           max-failed-builds: 1
261           fixed-delay: 90
262
263     publishers:
264       - fdio-infra-shiplogs:
265           maven-version: 'mvn33-new'