Use host_vars for wheel builds

No need to use magic names since we now have host_vars, instead set
wheel_python explicitly.

Remove TODO comment.

Change-Id: I5051a32d843b106b013b94d57fd24b63896b741a
This commit is contained in:
Andreas Jaeger 2018-02-17 16:27:57 +01:00
parent 3cb19258b8
commit fca8d78211
3 changed files with 13 additions and 20 deletions

View File

@ -1,9 +1,5 @@
- hosts: all
tasks:
- name: Select python version of build
set_fact:
wheel_python: "python{{ inventory_hostname[-1] }}"
- name: Ensure build logs directory exists
file:
path: "{{ zuul.executor.log_root }}/{{ wheel_python }}"

View File

@ -1,7 +1,3 @@
- name: Select python version to build
set_fact:
wheel_python: "python{{ inventory_hostname[-1] }}"
- name: Ensure wheel dir exists
file:
group: zuul

View File

@ -958,13 +958,12 @@
description: |
Build CentOS 7 wheels for OpenStaci CI mirrors.
nodeset:
# NOTE: The python2 and python3 suffix are important, they select the
# version of python to build in each job. (we pull the last character of
# the inventory_hostname)
# TODO(mordred): Replace the suffix with host_vars once we have them.
nodes:
- name: wheel-mirror-centos-7-python2
label: centos-7
host_vars:
wheel-mirror-ubuntu-centos-7-python2:
wheel_python: python2
- job:
name: publish-wheel-mirror-centos-7
@ -983,15 +982,16 @@
description: |
Build Ubuntu Trusty wheels for OpenStaci CI mirrors.
nodeset:
# NOTE: The python2 and python3 suffix are important, they select the
# version of python to build in each job. (we pull the last character of
# the inventory_hostname)
# TODO(mordred): Replace the suffix with host_vars once we have them.
nodes:
- name: wheel-mirror-ubuntu-trusty-python2
label: ubuntu-trusty
- name: wheel-mirror-ubuntu-trusty-python3
label: ubuntu-trusty
host_vars:
wheel-mirror-ubuntu-trusty-python2:
wheel_python: python2
wheel-mirror-ubuntu-trusty-python3:
wheel_python: python3
- job:
name: publish-wheel-mirror-ubuntu-trusty
@ -1010,15 +1010,16 @@
description: |
Build Ubuntu Xenial wheels for OpenStaci CI mirrors.
nodeset:
# NOTE: The python2 and python3 suffix are important, they select the
# version of python to build in each job. (we pull the last character of
# the inventory_hostname)
# TODO(mordred): Replace the suffix with host_vars once we have them.
nodes:
- name: wheel-mirror-ubuntu-xenial-python2
label: ubuntu-xenial
- name: wheel-mirror-ubuntu-xenial-python3
label: ubuntu-xenial
host_vars:
wheel-mirror-ubuntu-xenial-python2:
wheel_python: python2
wheel-mirror-ubuntu-xenial-python3:
wheel_python: python3
- job:
name: publish-wheel-mirror-ubuntu-xenial