Move zun pip packages from constraints to requirements

This is necessary to use the new pip resolver

Change-Id: Ia3782bf272a5970b6992d82e6732854af5e7a561
This commit is contained in:
Jonathan Rosser 2021-01-25 10:36:40 +00:00 committed by Dmitriy Rabotyagov
parent 67f1047af5
commit fe94ff67b3
2 changed files with 15 additions and 6 deletions

View File

@ -52,9 +52,6 @@ zun_kuryr_lib_git_install_branch: master
zun_upper_constraints_url: "{{ requirements_git_url | default('https://releases.openstack.org/constraints/upper/' ~ requirements_git_install_branch | default('master')) }}"
zun_git_constraints:
- "git+{{ zun_git_repo }}@{{ zun_git_install_branch }}#egg=zun"
- "git+{{ zun_kuryr_lib_git_repo }}@{{ zun_kuryr_lib_git_install_branch }}#egg=kuryr-lib"
- "git+{{ zun_kuryr_git_repo }}@{{ zun_kuryr_git_install_branch }}#egg=kuryr-libnetwork"
- "--constraint {{ zun_upper_constraints_url }}"
zun_pip_install_args: "{{ pip_install_options | default('') }}"
@ -304,7 +301,9 @@ zun_services:
# Common pip packages
zun_pip_packages:
- kuryr-libnetwork
- "git+{{ zun_git_repo }}@{{ zun_git_install_branch }}#egg=zun"
- "git+{{ zun_kuryr_lib_git_repo }}@{{ zun_kuryr_lib_git_install_branch }}#egg=kuryr-lib"
- "git+{{ zun_kuryr_git_repo }}@{{ zun_kuryr_git_install_branch }}#egg=kuryr-libnetwork"
- oslo_rootwrap
- osprofiler
- python-memcached
@ -312,7 +311,6 @@ zun_pip_packages:
- python-zunclient
- pymysql
- systemd-python
- zun
## (Qdrouterd) integration
# TODO(ansmith): Change structure when more backends will be supported

View File

@ -32,12 +32,23 @@
tags:
- zun-install
# NOTE(jrosser)
# kuryr-lib appears in u-c and the new pip resolver will fail to install
# if two contradictory constraints are given which will always happen
# with a source install and wheels built on the repo server. We must
# filter kuryr-lib out of u-c.
- name: Retrieve the constraints URL
uri:
url: "{{ zun_upper_constraints_url }}"
return_content: yes
register: _u_c_contents
- name: Install the python venv
import_role:
name: "python_venv_build"
vars:
venv_python_executable: "{{ zun_venv_python_executable }}"
venv_build_constraints: "{{ zun_git_constraints }}"
venv_build_constraints: "{{ _u_c_contents.content.split('\n') | reject('match', '[kuryr\\-lib=*]') | list }}"
venv_install_destination_path: "{{ zun_bin | dirname }}"
venv_install_distro_package_list: "{{ zun_distro_packages }}"
venv_pip_install_args: "{{ zun_pip_install_args }}"