Merge "Add generic tox job (multiple playbooks)" into feature/zuulv3
This commit is contained in:
commit
df8b742356
32
.zuul.yaml
32
.zuul.yaml
|
@ -1,15 +1,37 @@
|
|||
- job:
|
||||
name: python-linters
|
||||
pre-run: pre
|
||||
post-run: post
|
||||
name: base
|
||||
pre-run: base-pre
|
||||
post-run: base-post
|
||||
success-url: http://zuulv3-dev.openstack.org/logs/{build.uuid}/
|
||||
failure-url: http://zuulv3-dev.openstack.org/logs/{build.uuid}/
|
||||
timeout: 1800
|
||||
nodes:
|
||||
- name: worker
|
||||
- name: ubuntu-xenial
|
||||
image: ubuntu-xenial
|
||||
|
||||
- job:
|
||||
name: tox
|
||||
parent: base
|
||||
pre-run: tox-pre
|
||||
post-run: tox-post
|
||||
|
||||
- job:
|
||||
name: tox-cover
|
||||
parent: tox
|
||||
voting: false
|
||||
|
||||
- job:
|
||||
name: tox-linters
|
||||
parent: tox
|
||||
|
||||
- job:
|
||||
name: tox-py27
|
||||
parent: tox
|
||||
|
||||
- project:
|
||||
name: openstack-infra/zuul
|
||||
check:
|
||||
jobs:
|
||||
- python-linters
|
||||
- tox-cover
|
||||
- tox-linters
|
||||
- tox-py27
|
||||
|
|
|
@ -6,13 +6,7 @@
|
|||
mode: pull
|
||||
src: "/tmp/console.log"
|
||||
|
||||
- name: Collect tox logs.
|
||||
synchronize:
|
||||
dest: "{{ zuul.launcher.log_root }}/tox"
|
||||
mode: pull
|
||||
src: "/home/zuul/workspace/src/{{ zuul.project }}/.tox/pep8/log/"
|
||||
|
||||
- name: publish tox logs.
|
||||
- name: Publish logs.
|
||||
copy:
|
||||
dest: "/opt/zuul-logs/{{ zuul.uuid}}"
|
||||
src: "{{ zuul.launcher.log_root }}/"
|
|
@ -1,7 +0,0 @@
|
|||
- hosts: all
|
||||
tasks:
|
||||
- name: Run a tox -e pep8.
|
||||
include_role:
|
||||
name: run-tox
|
||||
vars:
|
||||
run_tox_eventlist: pep8
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
- name: Run install-distro-packages.sh
|
||||
shell: /usr/local/jenkins/slave_scripts/install-distro-packages.sh
|
||||
args:
|
||||
chdir: "/home/zuul/workspace/src/{{ zuul.project }}"
|
|
@ -1,3 +1,2 @@
|
|||
---
|
||||
# tasks/main.yaml
|
||||
run_tox_eventlist:
|
||||
run_tox_envlist:
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
- name: Run tox
|
||||
shell: "/usr/local/jenkins/slave_scripts/run-tox.sh {{ run_tox_eventlist }}"
|
||||
shell: "/usr/local/jenkins/slave_scripts/run-tox.sh {{ run_tox_envlist }}"
|
||||
args:
|
||||
chdir: "/home/zuul/workspace/src/{{ zuul.project }}"
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
- hosts: all
|
||||
vars:
|
||||
run_tox_envlist: cover
|
||||
roles:
|
||||
- run-tox
|
|
@ -0,0 +1,5 @@
|
|||
- hosts: all
|
||||
vars:
|
||||
run_tox_envlist: pep8
|
||||
roles:
|
||||
- run-tox
|
|
@ -0,0 +1,17 @@
|
|||
- hosts: all
|
||||
tasks:
|
||||
- name: Find tox directories to synchrionize.
|
||||
find:
|
||||
file_type: directory
|
||||
paths: "/home/zuul/workspace/src/{{ zuul.project }}/.tox"
|
||||
# NOTE(pabelanger): The .tox/log folder is empty, ignore it.
|
||||
patterns: ^(?!log).*$
|
||||
use_regex: yes
|
||||
register: result
|
||||
|
||||
- name: Collect tox logs.
|
||||
synchronize:
|
||||
dest: "{{ zuul.launcher.log_root }}/tox"
|
||||
mode: pull
|
||||
src: "{{ item.path }}/log/"
|
||||
with_items: "{{ result.files }}"
|
|
@ -0,0 +1,3 @@
|
|||
- hosts: all
|
||||
roles:
|
||||
- run-bindep
|
|
@ -0,0 +1,5 @@
|
|||
- hosts: all
|
||||
vars:
|
||||
run_tox_envlist: py27
|
||||
roles:
|
||||
- run-tox
|
Loading…
Reference in New Issue