Merge "Also pin pip/setuptools when creating Xenial venvs"

This commit is contained in:
Zuul 2022-08-11 00:19:46 +00:00 committed by Gerrit Code Review
commit 4ee5be00d9
2 changed files with 15 additions and 2 deletions

View File

@ -2,10 +2,22 @@
assert:
that: create_venv_path is defined
# Xenial's default pip will try to pull in packages that
# aren't compatible with 3.5. Cap them
- name: Setup bionic era venv
when: ansible_distribution_version is version('16.04', '==')
pip:
name:
- pip<21
- setuptools<51
state: latest
virtualenv: '{{ create_venv_path }}'
virtualenv_command: '/usr/bin/python3 -m venv'
# Bionic's default pip will try to pull in packages that
# aren't compatible with 3.6. Cap them
- name: Setup bionic era venv
when: ansible_distribution_release == 'bionic'
when: ansible_distribution_version is version('18.04', '==')
pip:
name:
- pip<22
@ -15,7 +27,7 @@
virtualenv_command: '/usr/bin/python3 -m venv'
- name: Setup later era venv
when: ansible_distribution_release != 'bionic'
when: ansible_distribution_version is version('20.04', '>=')
pip:
name:
- pip

View File

@ -392,6 +392,7 @@
- playbooks/bootstrap-bridge.yaml
- playbooks/roles/install-borg
- playbooks/roles/borg-backup
- playbooks/roles/create-venv
- playbooks/zuul/templates/host_vars/borg-backup
- testinfra/test_borg_backups.py
host-vars: