Change Ief366c092e05fb88351782f6d9cd280bfae96237 intoduced a bug in the streaming daemons because it was using Python 3.6 features. The streaming console needs to work on all Ansible managed nodes, which includes back to Python 2.7 nodes (while Ansible supports that). This introduces a regression test by building about the smallest Python 2.7 container that can be managed by Ansbile. We start this container and modify the test inventory to include it, then run the stream tests against it. The existing testing runs against the "new" console but also tests against the console OpenDev's Zuul starts to ensure backwards-compatability. Since this container wasn't started by Zuul it doesn't have this, so that testing is skipped for this node. It might be good to abstract all testing of the console daemons into separate containers for each Ansible supported managed-node Python version -- it's a bit more work than I want to take on right now. This should ensure the lower-bound though and prevent regressions for older platforms. Change-Id: Ia78ad9e3ec51bc47bf68c9ff38c0fcd16ba2e728
52 lines
1.5 KiB
YAML
52 lines
1.5 KiB
YAML
- hosts: controller
|
|
roles:
|
|
|
|
- role: ensure-pip
|
|
|
|
- role: bindep
|
|
bindep_profile: test
|
|
bindep_dir: src/opendev.org/zuul/zuul
|
|
|
|
post_tasks:
|
|
|
|
- name: Setup 2.7 container environment
|
|
include_tasks: 2.7-container.yaml
|
|
|
|
- name: Setup inventory
|
|
include_tasks: create-inventory.yaml
|
|
|
|
- name: Install pip
|
|
shell: |+
|
|
python3 -m pip install --upgrade pip setuptools wheel
|
|
become: yes
|
|
|
|
- name: Build wheel
|
|
shell:
|
|
chdir: src/opendev.org/zuul/zuul
|
|
cmd: |+
|
|
python3 setup.py bdist_wheel
|
|
|
|
- name: Install software
|
|
shell: |+
|
|
python3 -m pip install src/opendev.org/zuul/zuul/dist/*.whl
|
|
become: yes
|
|
|
|
- name: Install managed ansible versions
|
|
command: /usr/local/bin/zuul-manage-ansible -v
|
|
become: yes
|
|
environment:
|
|
# This appears to be necessary because without it the virtualenvs
|
|
# that virtualenv creates are not actually virtualenvs. They are just
|
|
# aliases for the root python installation instead. Then we try to
|
|
# install multiple ansible versions to the root (via multiple fake
|
|
# venvs) and the installation fails due to conflicts.
|
|
SETUPTOOLS_USE_DISTUTILS: stdlib
|
|
|
|
- name: Copy ansible.cfg
|
|
template:
|
|
src: templates/ansible.cfg.j2
|
|
dest: "{{ ansible_user_dir }}/ansible.cfg"
|
|
|
|
- name: Generate logging config
|
|
command: python3 src/opendev.org/zuul/zuul/zuul/ansible/logconfig.py
|