Support both python2 and python3 virtualenv

Now that nodepool support python3, allow our dsvm job to create the
appropriate virtualenv for the version of python we'd like to test.

Change-Id: Ib573bfcfd367a983d510238f2f6456ffd710a4ab
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
This commit is contained in:
Paul Belanger 2017-05-24 10:35:20 -04:00
parent c70b50a3a5
commit 6e34b65d62
No known key found for this signature in database
GPG Key ID: 611A80832067AF38
1 changed files with 6 additions and 1 deletions

View File

@ -61,7 +61,12 @@ function install_glean {
# Install nodepool code
function install_nodepool {
virtualenv $NODEPOOL_INSTALL
if python3_enabled; then
VENV="virtualenv -p python${PYTHON3_VERSION}"
else
VENV="virtualenv -p python${PYTHON2_VERSION}"
fi
$VENV $NODEPOOL_INSTALL
install_shade
install_diskimage_builder
install_glean