Removes nova from requirements.txt
Removes nova from the requirements.txt and instead add tools\tox_install.sh file, which takes care of installing nova. This is useful for Jenkins, as it needs nova in order to run its tests. Change-Id: Ia81a49b2cd35a17edfe5edab35bef42191c7f4af
This commit is contained in:
parent
44a06c533f
commit
35262e6301
|
@ -14,4 +14,3 @@ oslo.utils>=3.4.0 # Apache-2.0
|
|||
oslo.i18n>=2.1.0 # Apache-2.0
|
||||
|
||||
eventlet>=0.18.2 # MIT
|
||||
-e git+http://github.com/openstack/nova.git#egg=nova
|
||||
|
|
|
@ -0,0 +1,41 @@
|
|||
#!/bin/sh
|
||||
|
||||
# compute-hyperv repo depends on nova, which doesn't exist on pypi.
|
||||
|
||||
# This wrapper for tox's package installer will use the existing package
|
||||
# if it exists, else use zuul-cloner if that program exists, else grab it
|
||||
# from nova master via a hard-coded URL. That last case should only
|
||||
# happen with devs running unit tests locally.
|
||||
|
||||
# From the tox.ini config page:
|
||||
# install_command=ARGV
|
||||
# default:
|
||||
# pip install {opts} {packages}
|
||||
|
||||
ZUUL_CLONER=/usr/zuul-env/bin/zuul-cloner
|
||||
nova_installed=$(echo "import nova" | python 2>/dev/null ; echo $?)
|
||||
|
||||
set -e
|
||||
|
||||
if [ $nova_installed -eq 0 ]; then
|
||||
echo "ALREADY INSTALLED" > /tmp/tox_install.txt
|
||||
echo "Nova already installed; using existing package"
|
||||
elif [ -x "$ZUUL_CLONER" ]; then
|
||||
export ZUUL_BRANCH=${ZUUL_BRANCH-$BRANCH}
|
||||
echo "ZUUL CLONER" > /tmp/tox_install.txt
|
||||
cwd=$(/bin/pwd)
|
||||
cd /tmp
|
||||
$ZUUL_CLONER --cache-dir \
|
||||
/opt/git \
|
||||
git://git.openstack.org \
|
||||
openstack/nova
|
||||
cd openstack/nova
|
||||
pip install -e .
|
||||
cd "$cwd"
|
||||
else
|
||||
echo "PIP HARDCODE" > /tmp/tox_install.txt
|
||||
pip install -U -egit+https://git.openstack.org/openstack/nova#egg=nova
|
||||
fi
|
||||
|
||||
pip install -U $*
|
||||
exit $?
|
2
tox.ini
2
tox.ini
|
@ -8,7 +8,7 @@ usedevelop = True
|
|||
# tox is silly... these need to be separated by a newline....
|
||||
whitelist_externals = bash
|
||||
find
|
||||
install_command = pip install --allow-external -U --force-reinstall {opts} {packages}
|
||||
install_command = {toxinidir}/tools/tox_install.sh {opts} {packages}
|
||||
# Note the hash seed is set to 0 until hyperv can be tested with a
|
||||
# random hash seed successfully.
|
||||
setenv = VIRTUAL_ENV={envdir}
|
||||
|
|
Loading…
Reference in New Issue