It doesn't look like tox is using it's own virtualenv

Bug #1518652 reported by David Moreau Simard
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
kolla
Invalid
Low
David Moreau Simard

Bug Description

Here's a trace when attempting to run "build-centos-binary" out of the box:
http://paste.openstack.org/show/479665/

Out of curiosity, I installed testrepository globally with pip (for testr) and I then got the following trace:
http://paste.openstack.org/show/479664/

You can see in the stacktraces of the second paste that the python libraries used are the global ones, not the ones from the tox virtual environment.

Poking around in tox.ini, I could not find a way to fix this ?
Looking at other projects, such as Nova, you will see something like this which is missing in Kolla:
https://github.com/openstack/nova/blob/9b6938b2c62ebf32a707138fd9035d4fd00f23cc/tox.ini#L15

I tried to add that in, and that didn't fix it. Additional trial and error with a couple of other settings and I couldn't get it to work either.
Installing requirements and test-requirements globally works around this issue but is not really acceptable.

Revision history for this message
David Moreau Simard (dmsimard) wrote :

It looks like the culprit is sudo:
https://github.com/openstack/kolla/blob/00b7794f3ef463cd40f1fbabefd0e3180fd7c325/tox.ini#L45

Surely the virutalenv settings are lost in the process.
Removing sudo from the command in an environment where the user is member of the docker group yields a successful build.

In the gate setup, instead of adding jenkins as a sudoers for the docker group, couldn't we add him to the docker group outright instead and drop the sudo from tox ?

Changed in kolla:
assignee: nobody → David Moreau Simard (dmsimard)
status: New → In Progress
Revision history for this message
David Moreau Simard (dmsimard) wrote :
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on kolla (master)

Change abandoned by David Moreau Simard (<email address hidden>) on branch: master
Review: https://review.openstack.org/248416

Changed in kolla:
importance: Undecided → Low
Revision history for this message
Christian Berendt (berendt) wrote :

Closing this bug as invalid, it is older than 1 years. Please re-open this bug report if the bug still occurs.

Changed in kolla:
status: In Progress → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.