This repository has been archived by the owner on Jan 9, 2019. It is now read-only.
forked from openstack-infra/zuul-jobs
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathzuul.yaml
474 lines (346 loc) · 11.7 KB
/
zuul.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
# Shared jobs that are generally applicable to everyone
# Assumes a 'base' job defined elsewhere
- job:
name: unittests
abstract: true
description: |
Perform setup common to all unit test jobs.
This performs basic host and general project setup tasks common
to all types of unit test jobs.
pre-run: playbooks/unittests/pre.yaml
post-run: playbooks/unittests/post.yaml
- job:
name: tox
parent: unittests
description: |
Base job containing setup and teardown for tox-based test jobs.
This performs basic host and general project setup tasks common
to all tox unit test jobs.
Responds to these variables:
.. zuul:jobvar:: tox_envlist
Use the specified tox environments (``ALL`` selects all).
.. zuul:jobvar:: tox_environment
List of user defined environmental variables to pass to bash
shell.
.. zuul:jobvar:: tox_extra_args
String containing extra arguments to append to the tox command line.
.. zuul:jobvar: tox_constraints_file
Path to a pip constraints file. Will be provided to tox in the
UPPER_CONSTRAINTS_FILE environment variable if it exists.
.. zuul:jobvar: tox_install_siblings
:default: true
Override tox requirements that have corresponding zuul git repos
on the node by installing the git versions into the tox virtualenv.
run: playbooks/tox/run.yaml
pre-run: playbooks/tox/pre.yaml
post-run: playbooks/tox/post.yaml
vars:
tox_environment:
NOSE_WITH_HTML_OUTPUT: 1
NOSE_HTML_OUT_FILE: nose_results.html
NOSE_WITH_XUNIT: 1
- job:
name: tox-py27
parent: tox
description: |
Run unit tests for a Python project under cPython version 2.7.
Uses tox with the ``py27`` environment.
vars:
tox_envlist: py27
- job:
name: tox-py34
parent: tox
description: |
Run unit tests for a Python project under cPython version 3.4.
Uses tox with the ``py34`` environment.
vars:
tox_envlist: py34
- job:
name: tox-py35
parent: tox
description: |
Run unit tests for a Python project under cPython version 3.5.
Uses tox with the ``py35`` environment.
vars:
tox_envlist: py35
- job:
name: tox-py36
parent: tox
description: |
Run unit tests for a Python project under cPython version 3.6.
Uses tox with the ``py36`` environment.
vars:
tox_envlist: py36
- job:
name: tox-docs
parent: tox
description: |
Run documentation unit tests.
Uses tox with the ``docs`` environment.
vars:
tox_envlist: docs
post-run: playbooks/tox/docs-post.yaml
success-url: html/
- job:
name: tox-linters
parent: tox
description: |
Runs code linting tests.
Uses tox with the ``linters`` environment.
vars:
tox_envlist: linters
- job:
name: tox-pep8
parent: tox
description: |
Runs code pep8 tests.
Uses tox with the ``pep8`` environment.
vars:
tox_envlist: pep8
- job:
name: tox-cover
parent: tox
description: |
Run code coverage tests.
Uses tox with the ``cover`` environment.
post-run: playbooks/tox/cover-post.yaml
vars:
tox_envlist: cover
- job:
name: tox-bashate
parent: tox
description: |
Run bashate tests.
Uses tox with the ``bashate`` environment.
vars:
tox_envlist: bashate
- job:
name: tox-nodejs-npm
parent: tox
description: |
Run tests using tox but with the javascript toolchain installed
and available as well. A combination of the tox and nodejs-npm
jobs. By default will run npm before running the tox environment listed.
Responds to these variables:
.. zuul:jobvar:: tox_envlist
Use the specified tox environments (``ALL`` selects all).
.. zuul:jobvar:: tox_environment
List of user defined environmental variables to pass to bash
shell.
.. zuul:jobvar:: tox_extra_args
String containing extra arguments to append to the tox command line.
.. zuul:jobvar: tox_constraints_file
Path to a pip constraints file. Will be provided to tox in the
UPPER_CONSTRAINTS_FILE environment variable if it exists.
.. zuul:jobvar: tox_install_siblings
:default: true
Override tox requirements that have corresponding zuul git repos
on the node by installing the git versions into the tox virtualenv.
.. zuul:jobvar:: npm_command
:default: build
Command to pass to npm.
.. zuul:jobvar:: node_version
:default: 6
The version of Node to use.
.. zuul:jobvar: javascript_content_dir
:default: dist
Directory, relative to zuul_work_dir, holding build content.
.. zuul:jobvar: zuul_work_dir
:default: {{ zuul.project.src_dir }}
Path to operate in.
pre-run: playbooks/javascript/pre.yaml
run: playbooks/tox/npm.yaml
post-run: playbooks/javascript/post.yaml
vars:
npm_command: build
- job:
name: build-python-release
description: |
Build a source tarball and a bdist wheel for uploading.
run: playbooks/python/release.yaml
post-run: playbooks/python/tarball-post.yaml
- job:
name: python-upload-pypi
parent: build-python-release
description: |
Generate and upload a python source tarball and binary wheel
Requires a variable ``pypi_info`` be set which is a dict containing
at least a ``username`` and ``password`` attribute.
post-run: playbooks/python/upload-pypi.yaml
- job:
name: build-sphinx-docs
description: |
Build documentation using Sphinx
Additional requirements can be provided in a project in either the
file ``doc/requirements.txt`` or ``test-requirements.txt``. (The first
file found in that order will be the one used) Non-python distro
requirements can be specified in ``bindep.txt`` using the ``doc`` tag.
Runs `whereto https://docs.openstack.org/whereto/latest/` after the build
if it is installed.
Responds to these variables:
.. zuul:jobvar:: constraints_file
Optional path to a pip constraints file for installing python
libraries.
.. zuul:jobvar:: sphinx_python
:default: python2
Version of python to use, either ``python2`` or ``python3``.
.. zuul:jobvar:: zuul_work_dir
:default: {{ zuul.project.src_dir }}
Directory to operate in.
success-url: html/
pre-run: playbooks/sphinx/pre.yaml
run: playbooks/sphinx/run.yaml
post-run: playbooks/sphinx/post.yaml
- job:
name: build-reno-releasenotes
description: |
Build releasenotes using reno
Additional requirements can be provided in a project in either the
file ``doc/requirements.txt`` or ``test-requirements.txt``. (The first
file found in that order will be the one used) Non-python distro
requirements can be specified in ``bindep.txt`` using the ``doc`` tag.
Responds to these variables:
.. zuul:jobvar:: constraints_file
Optional path to a pip constraints file for installing python
libraries.
.. zuul:jobvar:: sphinx_python
:default: python2
Version of python to use, either ``python2`` or ``python3``.
.. zuul:jobvar:: zuul_work_dir
:default: {{ zuul.project.src_dir }}
Directory to operate in.
success-url: html/
# Release notes always build on master.
override-checkout: master
pre-run: playbooks/releasenotes/pre.yaml
run: playbooks/releasenotes/run.yaml
post-run: playbooks/releasenotes/post.yaml
files:
- ^releasenotes/.*
- bindep.txt
- doc/requirements.txt
- test-requirements.txt
- job:
name: trigger-readthedocs
description: Send a trigger to the readthedocs url to tell it to build docs
nodeset:
nodes: []
run: playbooks/python/readthedocs.yaml
- job:
name: multinode
abstract: true
description: |
Do additional setup needed for multi-node jobs such as setting up
overlay networks and setting up known-hosts and ssh keys
pre-run: playbooks/multinode/pre.yaml
- job:
name: nodejs-npm
parent: unittests
description: |
Base job for javascript operations
Responds to these variables:
.. zuul:jobvar:: npm_command
:default: build
Command to pass to npm.
.. zuul:jobvar:: node_version
:default: 6
The version of Node to use.
.. zuul:jobvar: zuul_work_dir
:default: {{ zuul.project.src_dir }}
Path to operate in.
.. zuul:jobvar: javascript_content_dir
:default: dist
Directory, relative to zuul_work_dir, holding build content.
pre-run: playbooks/javascript/pre.yaml
run: playbooks/javascript/run.yaml
post-run: playbooks/javascript/post.yaml
vars:
npm_command: build
- job:
name: build-javascript-tarball
parent: nodejs-npm
description: |
Build a source tarball for a Javascript project
Responds to these variables:
.. zuul:jobvar:: node_version
:default: 6
The version of Node to use.
.. zuul:jobvar: zuul_work_dir
:default: {{ zuul.project.src_dir }}
Path to operate in.
.. zuul:jobvar: javascript_content_dir
:default: dist
Directory, relative to zuul_work_dir, holding build content.
vars:
npm_command: pack
- job:
name: build-javascript-content
parent: nodejs-npm
description: |
Build javascript web content as it should be deployed.
Responds to these variables:
.. zuul:jobvar:: npm_command
:default: build
Command to pass to npm.
.. zuul:jobvar:: node_version
:default: 6
The version of Node to use.
.. zuul:jobvar: zuul_work_dir
:default: {{ zuul.project.src_dir }}
Path to operate in.
.. zuul:jobvar: javascript_content_dir
:default: dist
Directory, relative to zuul_work_dir, holding build content.
success-url: npm/html/
- job:
name: nodejs-npm-run-test
parent: nodejs-npm
description: |
Run test using nodejs. This test also starts Xvfb for run time
tests.
Responds to these variables:
.. zuul:jobvar:: node_version
:default: 6
The version of Node to use.
.. zuul:jobvar: zuul_work_dir
:default: {{ zuul.project.src_dir }}
Path to operate in.
.. zuul:jobvar: javascript_content_dir
:default: dist
Directory, relative to zuul_work_dir, holding build content.
pre-run: playbooks/javascript/pre-test.yaml
vars:
npm_command: test
- job:
name: nodejs-npm-run-lint
parent: nodejs-npm
description: |
Run lint using nodejs.
Responds to these variables:
.. zuul:jobvar:: node_version
:default: 6
The version of Node to use.
.. zuul:jobvar: zuul_work_dir
:default: {{ zuul.project.src_dir }}
Path to operate in.
.. zuul:jobvar: javascript_content_dir
:default: dist
Directory, relative to zuul_work_dir, holding build content.
vars:
npm_command: lint
- job:
name: nodejs-npm-run-docs
parent: nodejs-npm
description: |
Run docs using nodejs.
Responds to these variables:
.. zuul:jobvar:: node_version
:default: 6
The version of Node to use.
.. zuul:jobvar: zuul_work_dir
:default: {{ zuul.project.src_dir }}
Path to operate in.
post-run: playbooks/tox/docs-post.yaml
success-url: html/
vars:
npm_command: docs