ansible venv --system-site-packages causes conflicts

Bug #1657890 reported by Pas on 2017-01-19
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
openstack-ansible
Low
Praveen N

Bug Description

On ubuntu 16.10 yakkety (and probably on 16.04 xenial, where python-cffi-backend is 1.5.2) and using current master ( 42aaff7c5351e2520fcf5efc373041757519682a ) bootstrap installs python-cffi-backend distrib package, but then tries to install python package cryptography which somehow depends on python-cffi 1.9.

And then things inside the venv find the cffi from outside and produce an AssertionError version mismatch.

Editing ./scripts/bootstrap-ansible.sh works around this.

Praveen N (praveenn) on 2017-01-22
Changed in openstack-ansible:
assignee: nobody → Praveen N (praveenn)

Could you provide the code in question by a patch or here?

Avoiding duplication of work seems smarter :)

Changed in openstack-ansible:
status: New → Confirmed
importance: Undecided → Low
Pas (pasthelod) wrote :

Hello!

Sure, here's a diff for my bootstrap-ansible.sh:

diff --git a/scripts/bootstrap-ansible.sh b/scripts/bootstrap-ansible.sh
index caa74c7..b525dbf 100755
--- a/scripts/bootstrap-ansible.sh
+++ b/scripts/bootstrap-ansible.sh
@@ -96,7 +96,7 @@ fi

 # Create a Virtualenv for the Ansible runtime
 PYTHON_EXEC_PATH="$(which python2 || which python)"
-virtualenv --clear ${VIRTUALENV_OPTIONS} --system-site-packages --python="${PYTHON_EXEC_PATH}" /opt/ansible-runtime
+virtualenv --clear ${VIRTUALENV_OPTIONS} --python="${PYTHON_EXEC_PATH}" /opt/ansible-runtime

 # The vars used to prepare the Ansible runtime venv
 PIP_OPTS+=" --upgrade"

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers