49997db4f9f0ae9ff72be99b5d31f6d553acded3
[releng/builder.git] / jjb / releng-jobs.yaml
1 ---
2 - project:
3     name: builder-jobs
4     jobs:
5       - '{project-name}-ci-jobs'
6       - builder-check-poms
7       - gerrit-tox-verify
8       # OpenStack Related
9       - 'builder-verify-image-protection'
10       - 'builder-cleanup-old-images'
11       - 'builder-delete-orphaned-nodes'
12       - 'builder-delete-stale-nodes'
13       - 'builder-delete-stale-stacks'
14       # Automation for docs and jobs
15       - 'builder-update-image-list'
16
17     # The following values are only specified here
18     # so that code blocks look similar to other projects.
19     project: 'releng/builder'
20     project-name: builder
21     stream: master
22     branch: master
23     build-node: centos7-builder-2c-8g
24     archive-artifacts: '**/*.log'
25     build-timeout: 30
26     jjb-version: 2.0.0
27
28 - project:
29     name: packer-jobs
30     # packer jobs templates are defined in global-jjb
31     jobs:
32       - '{project-name}-packer-jobs'
33     project: 'releng/builder'
34     project-name: builder
35     branch: master
36     archive-artifacts: '**/*.log'
37     build-node: centos7-builder-2c-8g
38
39     platforms:
40       - centos
41       - ubuntu-14.04
42       - ubuntu-16.04
43
44     templates:
45       - devstack
46       - devstack-pre-pip-newton:
47           build-timeout: 75
48       - devstack-pre-pip-ocata:
49           build-timeout: 60
50       - devstack-pre-pip-pike:
51           build-timeout: 75
52       - gbp
53       - mininet-ovs-2.5:
54           build-timeout: 60
55       - mininet-ovs-2.6:
56           build-timeout: 75
57
58     exclude:
59       - platforms: centos
60         templates: gbp
61       - platforms: centos
62         templates: mininet-ovs-2.5
63       - platforms: centos
64         templates: mininet-ovs-2.6
65       - platforms: ubuntu-14.04
66         templates: devstack-pre-pip-newton
67       - platforms: ubuntu-14.04
68         templates: devstack-pre-pip-ocata
69       - platforms: ubuntu-14.04
70         templates: devstack-pre-pip-pike
71       - platforms: ubuntu-14.04
72         templates: devstack
73       - platforms: ubuntu-14.04
74         templates: mininet-ovs-2.5
75       - platforms: ubuntu-14.04
76         templates: mininet-ovs-2.6
77       - platforms: ubuntu-16.04
78         templates: devstack-pre-pip-newton
79       - platforms: ubuntu-16.04
80         templates: devstack-pre-pip-ocata
81       - platforms: ubuntu-16.04
82         templates: devstack-pre-pip-pike
83       - platforms: ubuntu-16.04
84         templates: devstack
85
86 - job-template:
87     name: builder-check-poms
88     node: centos7-builder-2c-8g
89
90     project-type: freestyle
91
92     properties:
93       - opendaylight-infra-properties:
94           build-days-to-keep: 14
95
96     parameters:
97       - opendaylight-infra-parameters:
98           os-cloud: '{os-cloud}'
99           project: '{project}'
100           branch: '{branch}'
101           refspec: 'refs/heads/{branch}'
102           artifacts: '{archive-artifacts}'
103
104     wrappers:
105       - opendaylight-infra-wrappers:
106           build-timeout: '{build-timeout}'
107
108     triggers:
109       - timed: 'H H * * 1'
110
111     builders:
112       - shell: !include-raw-escape: check-poms.sh
113
114     publishers:
115       - email-notification:
116           email-recipients: '{email-recipients}'
117           email-prefix: '[releng]'
118       - lf-infra-publish
119
120
121 - job-template:
122     name: 'builder-verify-image-protection'
123     project-type: freestyle
124     node: centos7-builder-2c-8g
125
126     properties:
127       - opendaylight-infra-properties:
128           build-days-to-keep: 7
129
130     parameters:
131       - opendaylight-infra-parameters:
132           os-cloud: '{os-cloud}'
133           project: '{project}'
134           branch: '{branch}'
135           refspec: 'refs/heads/{branch}'
136           artifacts: '{archive-artifacts}'
137
138     scm:
139       - git-scm:
140           branch: '{branch}'
141
142     wrappers:
143       - opendaylight-infra-wrappers:
144           build-timeout: '{build-timeout}'
145       # Listed after to override openstack-infra-wrappers clouds.yaml definition
146       - config-file-provider:
147           files:
148             - file-id: clouds-yaml
149               target: '$HOME/.config/openstack/clouds.yaml'
150
151     triggers:
152       - timed: '@daily'
153
154     builders:
155       - shell: !include-raw-escape:
156           - opendaylight-infra-check-image-protection.sh
157
158     publishers:
159       - email-notification:
160           email-recipients: '{email-recipients}'
161           email-prefix: '[releng]'
162       - lf-infra-publish
163
164
165 - job-template:
166     name: 'builder-cleanup-old-images'
167     project-type: freestyle
168     node: centos7-builder-2c-8g
169
170     properties:
171       - opendaylight-infra-properties:
172           build-days-to-keep: 7
173
174     parameters:
175       - opendaylight-infra-parameters:
176           os-cloud: '{os-cloud}'
177           project: '{project}'
178           branch: '{branch}'
179           refspec: 'refs/heads/{branch}'
180           artifacts: '{archive-artifacts}'
181
182     scm:
183       - git-scm:
184           branch: '{branch}'
185
186     wrappers:
187       - opendaylight-infra-wrappers:
188           build-timeout: '{build-timeout}'
189       # Listed after to override openstack-infra-wrappers clouds.yaml definition
190       - config-file-provider:
191           files:
192             - file-id: clouds-yaml
193               target: '$HOME/.config/openstack/clouds.yaml'
194
195     triggers:
196       # Cleanup images on a weekly schedule
197       - timed: '@weekly'
198
199     builders:
200       - shell: !include-raw-escape:
201           - global-jjb/shell/lftools-install.sh
202           - opendaylight-infra-cleanup-old-images.sh
203
204     publishers:
205       - email-notification:
206           email-recipients: '{email-recipients}'
207           email-prefix: '[releng]'
208       - lf-infra-publish
209
210
211 - job-template:
212     name: builder-delete-orphaned-nodes
213     project-type: freestyle
214     node: centos7-builder-2c-8g
215
216     properties:
217       - opendaylight-infra-properties:
218           build-days-to-keep: 7
219
220     parameters:
221       - opendaylight-infra-parameters:
222           os-cloud: '{os-cloud}'
223           project: '{project}'
224           branch: '{branch}'
225           refspec: 'refs/heads/{branch}'
226           artifacts: '{archive-artifacts}'
227       - string:
228           name: JENKINS_URLS
229           default: 'https://jenkins.opendaylight.org/releng https://jenkins.opendaylight.org/sandbox'
230           description: 'Space separated list of Jenkins URLs to check for active builds'
231
232     wrappers:
233       - opendaylight-infra-wrappers:
234           build-timeout: '{build-timeout}'
235
236     triggers:
237       # Attempt to clear up servers every 30 mins in case we have orphaned servers
238       - timed: '0,30 * * * *'
239
240     builders:
241       - shell: !include-raw-escape: opendaylight-infra-cleanup-orphaned-nodes.sh
242
243     publishers:
244       - email-notification:
245           email-recipients: '{email-recipients}'
246           email-prefix: '[releng]'
247       - lf-infra-publish
248
249
250 - job-template:
251     name: 'builder-delete-stale-nodes'
252     project-type: freestyle
253     node: centos7-builder-2c-8g
254
255     properties:
256       - opendaylight-infra-properties:
257           build-days-to-keep: 7
258
259     parameters:
260       - opendaylight-infra-parameters:
261           os-cloud: '{os-cloud}'
262           project: '{project}'
263           branch: '{branch}'
264           refspec: 'refs/heads/{branch}'
265           artifacts: '{archive-artifacts}'
266
267     wrappers:
268       - opendaylight-infra-wrappers:
269           build-timeout: '{build-timeout}'
270
271     triggers:
272       # Attempt to clear up stacks every 30 mins in case we have orphaned stacks
273       - timed: '0,30 * * * *'
274
275     builders:
276       - shell: !include-raw-escape:
277           - global-jjb/shell/lftools-install.sh
278           - opendaylight-infra-cleanup-stale-nodes.sh
279
280     publishers:
281       - email-notification:
282           email-recipients: '{email-recipients}'
283           email-prefix: '[releng]'
284       - lf-infra-publish
285
286
287 - job-template:
288     name: 'builder-delete-stale-stacks'
289     project-type: freestyle
290     node: centos7-builder-2c-8g
291
292     properties:
293       - opendaylight-infra-properties:
294           build-days-to-keep: 7
295
296     parameters:
297       - opendaylight-infra-parameters:
298           os-cloud: '{os-cloud}'
299           project: '{project}'
300           branch: '{branch}'
301           refspec: 'refs/heads/{branch}'
302           artifacts: '{archive-artifacts}'
303       - string:
304           name: JENKINS_URLS
305           default: 'https://jenkins.opendaylight.org/releng https://jenkins.opendaylight.org/sandbox'
306           description: 'Space separated list of Jenkins URLs to check for active builds'
307
308     wrappers:
309       - opendaylight-infra-wrappers:
310           build-timeout: '{build-timeout}'
311
312     triggers:
313       # Attempt to clear up stacks every 30 mins in case we have orphaned stacks
314       - timed: '0,30 * * * *'
315
316     builders:
317       - shell: !include-raw-escape: opendaylight-infra-cleanup-stale-stacks.sh
318
319     publishers:
320       - email-notification:
321           email-recipients: '{email-recipients}'
322           email-prefix: '[releng]'
323       - lf-infra-publish
324
325
326 - job-template:
327     name: 'builder-update-image-list'
328     project-type: freestyle
329     node: centos7-builder-2c-8g
330
331     properties:
332       - opendaylight-infra-properties:
333           build-days-to-keep: 7
334
335     parameters:
336       - opendaylight-infra-parameters:
337           os-cloud: vex
338           project: '{project}'
339           branch: '{branch}'
340           refspec: 'refs/heads/{branch}'
341           artifacts: '{archive-artifacts}'
342
343     scm:
344       - git-scm:
345           branch: '{branch}'
346
347     wrappers:
348       - opendaylight-infra-wrappers:
349           build-timeout: '{build-timeout}'
350       # Listed after to override openstack-infra-wrappers clouds.yaml definition
351       - config-file-provider:
352           files:
353             - file-id: clouds-yaml
354               target: '$HOME/.config/openstack/clouds.yaml'
355
356     triggers:
357       # Update image list every Monday to Friday at 11:00 UTC
358       - timed: '0 11 * * 1-5'
359
360     builders:
361       - shell: !include-raw-escape: opendaylight-infra-update-image-list.sh
362       - opendaylight-infra-push-gerrit-patch:
363           project: '{project}'
364           gerrit-topic: 'releng-update-cloud-image-list'
365           gerrit-commit-message: 'Update cloud image list docs'
366
367     publishers:
368       - email-notification:
369           email-recipients: '{email-recipients}'
370           email-prefix: '[releng]'
371       - lf-infra-publish