Fix virtualbmc installation after release of cryptography 3.4
Installing virtualbmc system-wide on CentOS 8 fails with: ModuleNotFoundError: No module named 'setuptools_rust' This error appeared following the release of cryptography 3.4, which now includes Rust code. It can be installed without Rust using a Python wheel, but only with more recent pip than version 9.0.3 available as RPM on CentOS 8. The cryptography bug report [1] recommends pip>=19.1.1. Also ignore PyYAML when installing system-wide to avoid conflicts with an existing RPM package installation. [1] https://github.com/pyca/cryptography/issues/5753 Change-Id: Ibd61e090611b3b7a7e0670c854362b512454bf3c Story: 2008607 Task: 41788
This commit is contained in:
parent
0719f06a6b
commit
f34bb772a0
@ -18,12 +18,25 @@
|
|||||||
retries: 3
|
retries: 3
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
|
# NOTE(priteau): We need a recent pip to install the latest cryptography
|
||||||
|
# library. See https://github.com/pyca/cryptography/issues/5753
|
||||||
|
- name: Ensure a recent version of pip is installed
|
||||||
|
pip:
|
||||||
|
name: "pip>=19.1.1"
|
||||||
|
virtualenv: "{{ vbmcd_virtualenv_path or omit }}"
|
||||||
|
become: "{{ not vbmcd_virtualenv_path }}"
|
||||||
|
|
||||||
- name: Ensure Python requirements are installed
|
- name: Ensure Python requirements are installed
|
||||||
pip:
|
pip:
|
||||||
name:
|
name:
|
||||||
- "virtualbmc>=1.4.0{% if ansible_python.version.major == 2 %},<2{% endif %}"
|
- "virtualbmc>=1.4.0{% if ansible_python.version.major == 2 %},<2{% endif %}"
|
||||||
|
# NOTE(priteau): Ignore PyYAML when installing system-wide to avoid the
|
||||||
|
# following error: Cannot uninstall 'PyYAML'. It is a distutils installed
|
||||||
|
# project and thus we cannot accurately determine which files belong to it
|
||||||
|
# which would lead to only a partial uninstall.
|
||||||
extra_args: >-
|
extra_args: >-
|
||||||
-c {{ vbmcd_python_upper_constraints_url }}
|
-c {{ vbmcd_python_upper_constraints_url }}
|
||||||
|
{% if not vbmcd_virtualenv_path %}--ignore-installed PyYAML{% endif %}
|
||||||
virtualenv: "{{ vbmcd_virtualenv_path or omit }}"
|
virtualenv: "{{ vbmcd_virtualenv_path or omit }}"
|
||||||
register: result
|
register: result
|
||||||
until: result is success
|
until: result is success
|
||||||
|
@ -0,0 +1,6 @@
|
|||||||
|
---
|
||||||
|
fixes:
|
||||||
|
- |
|
||||||
|
Fixes system-wide installation of virtualbmc following the release of
|
||||||
|
version 3.4 of the cryptography package. See `story 2008607
|
||||||
|
<https://storyboard.openstack.org/#!/story/2008607>`__ for details.
|
Loading…
Reference in New Issue
Block a user