Merge "Ensure wheel exists for build-release-python"
This commit is contained in:
commit
983a93efb2
1
.gitignore
vendored
1
.gitignore
vendored
@ -12,3 +12,4 @@ doc/build
|
||||
# pbr generates these
|
||||
AUTHORS
|
||||
ChangeLog
|
||||
dist
|
||||
|
@ -11,6 +11,7 @@ Python Roles
|
||||
.. zuul:autorole:: ensure-tox
|
||||
.. zuul:autorole:: ensure-twine
|
||||
.. zuul:autorole:: ensure-virtualenv
|
||||
.. zuul:autorole:: ensure-wheel
|
||||
.. zuul:autorole:: fetch-coverage-output
|
||||
.. zuul:autorole:: fetch-python-sdist-output
|
||||
.. zuul:autorole:: fetch-sphinx-output
|
||||
|
4
playbooks/python/release-pre.yaml
Normal file
4
playbooks/python/release-pre.yaml
Normal file
@ -0,0 +1,4 @@
|
||||
- hosts: all
|
||||
roles:
|
||||
- role: ensure-wheel
|
||||
wheel_python: "{{ release_python | default(python) }}"
|
@ -5,8 +5,7 @@ Build sdist and wheel for Python projects.
|
||||
.. zuul:rolevar:: release_python
|
||||
:default: python
|
||||
|
||||
The python interpreter to use. Set it to "python3" to use python 3,
|
||||
for example.
|
||||
The python interpreter to use. Defaults to "python".
|
||||
|
||||
.. zuul:rolevar:: bdist_wheel_xargs
|
||||
:default: ''
|
||||
|
9
roles/ensure-wheel/README.rst
Normal file
9
roles/ensure-wheel/README.rst
Normal file
@ -0,0 +1,9 @@
|
||||
Ensure wheel exists for Python projects.
|
||||
|
||||
**Role Variables**
|
||||
|
||||
.. zuul:rolevar:: wheel_python
|
||||
:default: python3
|
||||
|
||||
The python interpreter to use. Defaults to "python3".
|
||||
|
1
roles/ensure-wheel/defaults/main.yaml
Normal file
1
roles/ensure-wheel/defaults/main.yaml
Normal file
@ -0,0 +1 @@
|
||||
wheel_python: python3
|
15
roles/ensure-wheel/tasks/main.yaml
Normal file
15
roles/ensure-wheel/tasks/main.yaml
Normal file
@ -0,0 +1,15 @@
|
||||
- name: Check for wheel
|
||||
command: "{{ wheel_python }} -m wheel"
|
||||
failed_when: false
|
||||
register: wheel_exists
|
||||
|
||||
- name: Include ensure-pip
|
||||
vars:
|
||||
ensure_pip_from_upstream_interpreters: "{{ wheel_python }}"
|
||||
include_role:
|
||||
name: ensure-pip
|
||||
when: wheel_exists.rc != 0
|
||||
|
||||
- name: Install wheel
|
||||
command: "{{ wheel_python }} -m pip install --user wheel"
|
||||
when: wheel_exists.rc != 0
|
@ -1,11 +1,225 @@
|
||||
- job:
|
||||
name: zuul-jobs-test-build-python-release-jobs
|
||||
description: Test the build-python-release-jobs role
|
||||
files:
|
||||
- roles/build-python-release/.*
|
||||
- setup.cfg
|
||||
- setup.py
|
||||
vars:
|
||||
role_name: build-python-release
|
||||
release_python: python3
|
||||
pre-run: playbooks/python/release-pre.yaml
|
||||
run: test-playbooks/simple-role-test.yaml
|
||||
tags: all-platforms
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-build-python-release-jobs-centos-7
|
||||
description: Test the build-python-release-jobs role on centos-7
|
||||
parent: zuul-jobs-test-build-python-release-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: centos-7
|
||||
label: centos-7
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-build-python-release-jobs-centos-8
|
||||
description: Test the build-python-release-jobs role on centos-8
|
||||
parent: zuul-jobs-test-build-python-release-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: centos-8
|
||||
label: centos-8
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-build-python-release-jobs-debian-stretch
|
||||
description: Test the build-python-release-jobs role on debian-stretch
|
||||
parent: zuul-jobs-test-build-python-release-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: debian-stretch
|
||||
label: debian-stretch
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-build-python-release-jobs-fedora-31
|
||||
description: Test the build-python-release-jobs role on fedora-31
|
||||
parent: zuul-jobs-test-build-python-release-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: fedora-31
|
||||
label: fedora-31
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-build-python-release-jobs-gentoo-17-0-systemd
|
||||
description: Test the build-python-release-jobs role on gentoo-17-0-systemd
|
||||
parent: zuul-jobs-test-build-python-release-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: gentoo-17-0-systemd
|
||||
label: gentoo-17-0-systemd
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-build-python-release-jobs-opensuse-15
|
||||
description: Test the build-python-release-jobs role on opensuse-15
|
||||
parent: zuul-jobs-test-build-python-release-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: opensuse-15
|
||||
label: opensuse-15
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-build-python-release-jobs-opensuse-tumbleweed-nv
|
||||
voting: false
|
||||
description: Test the build-python-release-jobs role on opensuse-tumbleweed
|
||||
parent: zuul-jobs-test-build-python-release-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: opensuse-tumbleweed
|
||||
label: opensuse-tumbleweed
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-build-python-release-jobs-ubuntu-bionic
|
||||
description: Test the build-python-release-jobs role on ubuntu-bionic
|
||||
parent: zuul-jobs-test-build-python-release-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: ubuntu-bionic
|
||||
label: ubuntu-bionic
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-build-python-release-jobs-ubuntu-xenial
|
||||
description: Test the build-python-release-jobs role on ubuntu-xenial
|
||||
parent: zuul-jobs-test-build-python-release-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: ubuntu-xenial
|
||||
label: ubuntu-xenial
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-ensure-wheel-jobs
|
||||
description: Test the ensure-wheel role
|
||||
files:
|
||||
- roles/ensure-wheel/.*
|
||||
- setup.cfg
|
||||
- setup.py
|
||||
vars:
|
||||
role_name: ensure-wheel
|
||||
run: test-playbooks/simple-role-test.yaml
|
||||
tags: all-platforms
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-ensure-wheel-jobs-centos-7
|
||||
description: Test the ensure-wheel role on centos-7
|
||||
parent: zuul-jobs-test-ensure-wheel-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: centos-7
|
||||
label: centos-7
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-ensure-wheel-jobs-centos-8
|
||||
description: Test the ensure-wheel role on centos-8
|
||||
parent: zuul-jobs-test-ensure-wheel-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: centos-8
|
||||
label: centos-8
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-ensure-wheel-jobs-debian-stretch
|
||||
description: Test the ensure-wheel role on debian-stretch
|
||||
parent: zuul-jobs-test-ensure-wheel-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: debian-stretch
|
||||
label: debian-stretch
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-ensure-wheel-jobs-fedora-31
|
||||
description: Test the ensure-wheel role on fedora-31
|
||||
parent: zuul-jobs-test-ensure-wheel-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: fedora-31
|
||||
label: fedora-31
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-ensure-wheel-jobs-gentoo-17-0-systemd
|
||||
description: Test the ensure-wheel role on gentoo-17-0-systemd
|
||||
parent: zuul-jobs-test-ensure-wheel-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: gentoo-17-0-systemd
|
||||
label: gentoo-17-0-systemd
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-ensure-wheel-jobs-opensuse-15
|
||||
description: Test the ensure-wheel role on opensuse-15
|
||||
parent: zuul-jobs-test-ensure-wheel-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: opensuse-15
|
||||
label: opensuse-15
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-ensure-wheel-jobs-opensuse-tumbleweed-nv
|
||||
voting: false
|
||||
description: Test the ensure-wheel role on opensuse-tumbleweed
|
||||
parent: zuul-jobs-test-ensure-wheel-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: opensuse-tumbleweed
|
||||
label: opensuse-tumbleweed
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-ensure-wheel-jobs-ubuntu-bionic
|
||||
description: Test the ensure-wheel role on ubuntu-bionic
|
||||
parent: zuul-jobs-test-ensure-wheel-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: ubuntu-bionic
|
||||
label: ubuntu-bionic
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-ensure-wheel-jobs-ubuntu-xenial
|
||||
description: Test the ensure-wheel role on ubuntu-xenial
|
||||
parent: zuul-jobs-test-ensure-wheel-jobs
|
||||
tags: auto-generated
|
||||
nodeset:
|
||||
nodes:
|
||||
- name: ubuntu-xenial
|
||||
label: ubuntu-xenial
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-ensure-python-pyenv
|
||||
description: Test the ensure-python role with pyenv
|
||||
files:
|
||||
- zuul-tests.d/python-roles-jobs.yaml
|
||||
- roles/ensure-python/.*
|
||||
- test-playbooks/ensure-python-pyenv.yaml
|
||||
run: test-playbooks/ensure-python-pyenv.yaml
|
||||
tags: all-platforms
|
||||
|
||||
# -* AUTOGENERATED *-
|
||||
# The following project section is autogenerated by
|
||||
# tools/update-test-platforms.py
|
||||
# Please re-run to generate new job lists
|
||||
|
||||
- job:
|
||||
name: zuul-jobs-test-ensure-python-pyenv-centos-7
|
||||
description: Test the ensure-python role with pyenv on centos-7
|
||||
@ -100,6 +314,24 @@
|
||||
- project:
|
||||
check:
|
||||
jobs:
|
||||
- zuul-jobs-test-build-python-release-jobs-centos-7
|
||||
- zuul-jobs-test-build-python-release-jobs-centos-8
|
||||
- zuul-jobs-test-build-python-release-jobs-debian-stretch
|
||||
- zuul-jobs-test-build-python-release-jobs-fedora-31
|
||||
- zuul-jobs-test-build-python-release-jobs-gentoo-17-0-systemd
|
||||
- zuul-jobs-test-build-python-release-jobs-opensuse-15
|
||||
- zuul-jobs-test-build-python-release-jobs-opensuse-tumbleweed-nv
|
||||
- zuul-jobs-test-build-python-release-jobs-ubuntu-bionic
|
||||
- zuul-jobs-test-build-python-release-jobs-ubuntu-xenial
|
||||
- zuul-jobs-test-ensure-wheel-jobs-centos-7
|
||||
- zuul-jobs-test-ensure-wheel-jobs-centos-8
|
||||
- zuul-jobs-test-ensure-wheel-jobs-debian-stretch
|
||||
- zuul-jobs-test-ensure-wheel-jobs-fedora-31
|
||||
- zuul-jobs-test-ensure-wheel-jobs-gentoo-17-0-systemd
|
||||
- zuul-jobs-test-ensure-wheel-jobs-opensuse-15
|
||||
- zuul-jobs-test-ensure-wheel-jobs-opensuse-tumbleweed-nv
|
||||
- zuul-jobs-test-ensure-wheel-jobs-ubuntu-bionic
|
||||
- zuul-jobs-test-ensure-wheel-jobs-ubuntu-xenial
|
||||
- zuul-jobs-test-ensure-python-pyenv-centos-7
|
||||
- zuul-jobs-test-ensure-python-pyenv-centos-8
|
||||
- zuul-jobs-test-ensure-python-pyenv-debian-stretch
|
||||
@ -111,6 +343,22 @@
|
||||
- zuul-jobs-test-ensure-python-pyenv-ubuntu-xenial
|
||||
gate:
|
||||
jobs:
|
||||
- zuul-jobs-test-build-python-release-jobs-centos-7
|
||||
- zuul-jobs-test-build-python-release-jobs-centos-8
|
||||
- zuul-jobs-test-build-python-release-jobs-debian-stretch
|
||||
- zuul-jobs-test-build-python-release-jobs-fedora-31
|
||||
- zuul-jobs-test-build-python-release-jobs-gentoo-17-0-systemd
|
||||
- zuul-jobs-test-build-python-release-jobs-opensuse-15
|
||||
- zuul-jobs-test-build-python-release-jobs-ubuntu-bionic
|
||||
- zuul-jobs-test-build-python-release-jobs-ubuntu-xenial
|
||||
- zuul-jobs-test-ensure-wheel-jobs-centos-7
|
||||
- zuul-jobs-test-ensure-wheel-jobs-centos-8
|
||||
- zuul-jobs-test-ensure-wheel-jobs-debian-stretch
|
||||
- zuul-jobs-test-ensure-wheel-jobs-fedora-31
|
||||
- zuul-jobs-test-ensure-wheel-jobs-gentoo-17-0-systemd
|
||||
- zuul-jobs-test-ensure-wheel-jobs-opensuse-15
|
||||
- zuul-jobs-test-ensure-wheel-jobs-ubuntu-bionic
|
||||
- zuul-jobs-test-ensure-wheel-jobs-ubuntu-xenial
|
||||
- zuul-jobs-test-ensure-python-pyenv-centos-7
|
||||
- zuul-jobs-test-ensure-python-pyenv-centos-8
|
||||
- zuul-jobs-test-ensure-python-pyenv-debian-stretch
|
||||
|
@ -249,7 +249,7 @@
|
||||
name: build-python-release
|
||||
description: |
|
||||
Build a source tarball and a bdist wheel for uploading.
|
||||
pre-run: playbooks/python/pre.yaml
|
||||
pre-run: playbooks/python/release-pre.yaml
|
||||
run: playbooks/python/release.yaml
|
||||
post-run: playbooks/python/tarball-post.yaml
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user