feat: remove deprecated jenkins jobs
[ci-management.git] / jjb / hicn / hicn.yaml
1 # Copyright (c) 2021 Cisco and/or its affiliates.
2 # Licensed under the Apache License, Version 2.0 (the "License");
3 # you may not use this file except in compliance with the License.
4 # You may obtain a copy of the License at:
5 #
6 #     http://www.apache.org/licenses/LICENSE-2.0
7 #
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS,
10 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 # See the License for the specific language governing permissions and
12 # limitations under the License.
13
14 ---
15 - project:
16     name: hicn-x86_64
17     jobs:
18       - "hicn-verify-{stream}-{os}-{executor-arch}"
19       - "hicn-merge-{stream}-{os}-{executor-arch}"
20     project: "hicn"
21     os: ubuntu2004
22     executor-arch: "x86_64"
23     stream:
24       - "master":
25           branch: "master"
26
27 - project:
28     name: hicn-aarch64
29     jobs:
30       - "hicn-verify-{stream}-{os}-{executor-arch}"
31       - "hicn-merge-{stream}-{os}-{executor-arch}"
32     project: "hicn"
33     os: ubuntu2004
34     executor-arch: "aarch64"
35     stream:
36       - master:
37           branch: "master"
38
39 - project:
40     name: hicn-misc
41     jobs:
42       - "hicn-checkstyle-verify-{stream}-{os}-{executor-arch}"
43     project: "hicn"
44     stream:
45       - master:
46           branch: "master"
47     os: ubuntu2004
48     executor-arch: "x86_64"
49
50 - project:
51     name: hicn-extras-x86_64
52     jobs:
53       - "hicn-extras-verify-{stream}-{os}-{executor-arch}"
54       - "hicn-extras-build-{stream}-{os}-{executor-arch}"
55     project: "hicn"
56     os: ubuntu2004
57     executor-arch: "x86_64"
58     stream:
59       - master:
60           branch: "master"
61
62 - project:
63     name: hicn-extras-aarch64
64     jobs:
65       - "hicn-extras-verify-{stream}-{os}-{executor-arch}"
66       - "hicn-extras-build-{stream}-{os}-{executor-arch}"
67     project: "hicn"
68     os: ubuntu2004
69     executor-arch: "aarch64"
70     stream:
71       - master:
72           branch: "master"
73
74 - project:
75     name: hicn-view
76     views:
77       - project-view
78     project-name: hicn
79
80 - job-template:
81     name: "hicn-checkstyle-verify-{stream}-{os}-{executor-arch}"
82
83     project-type: freestyle
84     node: "builder-{os}-prod-{executor-arch}"
85     concurrent: true
86
87     properties:
88       - lf-infra-properties:
89           build-days-to-keep: "{build-days-to-keep}"
90
91     parameters:
92       - project-parameter:
93           project: "{project}"
94       - gerrit-parameter:
95           branch: "{branch}"
96       - os-parameter:
97           os: "{os}"
98
99     scm:
100       - gerrit-trigger-scm:
101           credentials-id: "jenkins-gerrit-credentials"
102           refspec: "$GERRIT_REFSPEC"
103           choosing-strategy: "gerrit"
104
105     wrappers:
106       - fdio-infra-wrappers:
107           build-timeout: "{build-timeout}"
108
109     triggers:
110       - gerrit:
111           server-name: "Primary"
112           trigger-on:
113             - patchset-created-event:
114                 exclude-drafts: "true"
115                 exclude-trivial-rebase: "false"
116                 exclude-no-code-change: "true"
117             - draft-published-event
118             - comment-added-contains-event:
119                 comment-contains-value: "checkstylecheck"
120             - comment-added-contains-event:
121                 comment-contains-value: "docsonly"
122             - comment-added-contains-event:
123                 comment-contains-value: "recheck"
124             - comment-added-contains-event:
125                 comment-contains-value: "reverify"
126           projects:
127             - project-compare-type: "ANT"
128               project-pattern: "{project}"
129               branches:
130                 - branch-compare-type: "ANT"
131                   branch-pattern: "**/{branch}"
132               file-paths:
133                 - compare-type: REG_EXP
134                   pattern: ^((?!\/COMMIT_MSG|docs|_abc|_def[\/\.]).)*$
135               disable-strict-forbidden-file-verification: "true"
136           override-votes: true
137           gerrit-build-notbuilt-verified-value: 0
138           gerrit-build-successful-verified-value: 1
139           # yamllint disable-line rule:line-length
140           notbuilt-message: "Automatic retry of failed jobs may be in process. A proper vote should be set when retry completes."
141           # yamllint disable-line rule:line-length
142           failed-message: "Checkstyle failed. No further verify jobs will be started."
143           successful-message: "checkstyle_success"
144           skip-vote:
145             successful: true
146             failed: false
147             unstable: false
148             notbuilt: false
149
150     builders:
151       - shell: !include-raw-escape:
152           - ../scripts/setup_executor_env.sh
153       - shell: !include-raw-escape:
154           - ../scripts/hicn/checkstyle.sh
155
156     publishers:
157       - fdio-infra-publish
158       - naginator:
159           rerun-unstable-builds: true
160           max-failed-builds: 1
161           fixed-delay: 90
162
163 - job-template:
164     name: "hicn-verify-{stream}-{os}-{executor-arch}"
165
166     project-type: freestyle
167     node: "builder-{os}-prod-{executor-arch}"
168     concurrent: true
169
170     properties:
171       - lf-infra-properties:
172           build-days-to-keep: "{build-days-to-keep}"
173
174     parameters:
175       - project-parameter:
176           project: "{project}"
177       - gerrit-parameter:
178           branch: "{branch}"
179       - os-parameter:
180           os: "{os}"
181       - stream-parameter:
182           stream: "{stream}"
183
184     scm:
185       - gerrit-trigger-scm:
186           credentials-id: "jenkins-gerrit-credentials"
187           refspec: "$GERRIT_REFSPEC"
188           choosing-strategy: "gerrit"
189
190     wrappers:
191       - fdio-infra-wrappers:
192           build-timeout: 120
193
194     triggers:
195       - gerrit-trigger-checkstyle:
196           name: "{project}"
197           branch: "{branch}"
198
199     builders:
200       - shell: !include-raw-escape:
201           - ../scripts/setup_executor_env.sh
202       - shell: !include-raw-escape:
203           - ../scripts/hicn/build.sh
204
205     publishers:
206       - fdio-infra-publish
207
208 - job-template:
209     name: "hicn-merge-{stream}-{os}-{executor-arch}"
210
211     project-type: freestyle
212     node: "builder-{os}-prod-{executor-arch}"
213
214     properties:
215       - lf-infra-properties:
216           build-days-to-keep: "{build-days-to-keep}"
217
218     parameters:
219       - project-parameter:
220           project: "{project}"
221       - gerrit-parameter:
222           branch: "{branch}"
223       - os-parameter:
224           os: "{os}"
225       - stream-parameter:
226           stream: "{stream}"
227
228     scm:
229       - gerrit-trigger-scm:
230           credentials-id: "jenkins-gerrit-credentials"
231           refspec: ""
232           choosing-strategy: "default"
233
234     wrappers:
235       - fdio-infra-wrappers:
236           build-timeout: "{build-timeout}"
237
238     triggers:
239       - gerrit-trigger-patch-merged:
240           name: "{project}"
241           branch: "{branch}"
242
243     builders:
244       - config-file-provider:
245           files:
246             - file-id: ".packagecloud"
247               target: "/root/.packagecloud"
248       - config-file-provider:
249           files:
250             - file-id: "packagecloud_api"
251               target: "/root/packagecloud_api"
252       - shell: !include-raw-escape:
253           - ../scripts/setup_executor_env.sh
254       - shell: !include-raw-escape:
255           - ../scripts/hicn/checkstyle.sh
256       - shell: !include-raw-escape:
257           - ../scripts/hicn/build.sh
258       - shell: !include-raw-escape:
259           - ../scripts/packagecloud_push.sh
260
261     publishers:
262       - fdio-infra-publish
263
264 - project:
265     name: hicn-sonar
266     project: hicn
267     project-name: hicn
268     mvn-settings: hicn-settings
269     sonarcloud: true
270     sonarcloud-project-organization: "{sonarcloud_project_organization}"
271     sonarcloud-api-token: "{sonarcloud_api_token}"
272     sonarcloud-project-key: "{sonarcloud_project_organization}_{project-name}"
273     branch: master
274     build-node: centos7-docker-2c-2g
275     jobs:
276       - gerrit-maven-sonar
277
278 - job-template:
279     name: "hicn-extras-verify-{stream}-{os}-{executor-arch}"
280
281     project-type: freestyle
282     node: "builder-{os}-prod-{executor-arch}"
283     concurrent: true
284
285     properties:
286       - lf-infra-properties:
287           build-days-to-keep: "{build-days-to-keep}"
288
289     parameters:
290       - project-parameter:
291           project: "{project}"
292       - gerrit-parameter:
293           branch: "{branch}"
294       - os-parameter:
295           os: "{os}"
296       - stream-parameter:
297           stream: "{stream}"
298
299     scm:
300       - gerrit-trigger-scm:
301           credentials-id: "jenkins-gerrit-credentials"
302           refspec: "$GERRIT_REFSPEC"
303           choosing-strategy: "gerrit"
304
305     wrappers:
306       - fdio-infra-wrappers:
307           build-timeout: 120
308
309     triggers:
310       - gerrit:
311           server-name: "Primary"
312           trigger-on:
313             - comment-added-contains-event:
314                 comment-contains-value: "verify-extras"
315           projects:
316             - project-compare-type: "ANT"
317               project-pattern: "{project}"
318               branches:
319                 - branch-compare-type: "ANT"
320                   branch-pattern: "**/{branch}"
321
322     builders:
323       - shell: !include-raw-escape:
324           - ../scripts/setup_executor_env.sh
325       - shell: !include-raw-escape:
326           - ../scripts/hicn/build-extras.sh
327
328     publishers:
329       - fdio-infra-publish
330
331 - job-template:
332     name: "hicn-extras-build-{stream}-{os}-{executor-arch}"
333
334     project-type: freestyle
335     node: "builder-{os}-prod-{executor-arch}"
336
337     properties:
338       - lf-infra-properties:
339           build-days-to-keep: "{build-days-to-keep}"
340
341     parameters:
342       - project-parameter:
343           project: "{project}"
344       - gerrit-parameter:
345           branch: "{branch}"
346       - os-parameter:
347           os: "{os}"
348       - stream-parameter:
349           stream: "hicn"
350
351     scm:
352       - gerrit-trigger-scm:
353           credentials-id: "jenkins-gerrit-credentials"
354           refspec: ""
355           choosing-strategy: "default"
356
357     wrappers:
358       - fdio-infra-wrappers:
359           build-timeout: "{build-timeout}"
360
361     triggers:
362       - gerrit:
363           server-name: "Primary"
364           trigger-on:
365             - comment-added-contains-event:
366                 comment-contains-value: "build-extras"
367           projects:
368             - project-compare-type: "ANT"
369               project-pattern: "{project}"
370               branches:
371                 - branch-compare-type: "ANT"
372                   branch-pattern: "**/{branch}"
373
374     builders:
375       - config-file-provider:
376           files:
377             - file-id: ".packagecloud"
378               target: "/root/.packagecloud"
379       - config-file-provider:
380           files:
381             - file-id: "packagecloud_api"
382               target: "/root/packagecloud_api"
383       - shell: !include-raw-escape:
384           - ../scripts/setup_executor_env.sh
385       - shell: !include-raw-escape:
386           - ../scripts/hicn/build-extras.sh
387       - shell: !include-raw-escape:
388           - ../scripts/packagecloud_push.sh
389
390     publishers:
391       - fdio-infra-publish
392
393 - project:
394     name: hicn-info
395     project-name: hicn
396     jobs:
397       - gerrit-info-yaml-verify
398     build-node: centos7-builder-2c-2g
399     project: hicn
400     branch: master