From: Loic Dachary Date: Sat, 30 May 2015 08:53:51 +0000 (+0200) Subject: install-deps.sh: do not store pip cache outside of the tree X-Git-Tag: v9.0.2~84^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F4799%2Fhead;p=ceph.git install-deps.sh: do not store pip cache outside of the tree Signed-off-by: Loic Dachary --- diff --git a/install-deps.sh b/install-deps.sh index a8954fd99bfd..4df059a2cd04 100755 --- a/install-deps.sh +++ b/install-deps.sh @@ -94,6 +94,13 @@ function get_pip_and_wheel() { pip --timeout 300 $install 'setuptools >= 0.8' 'pip >= 7.0' 'wheel >= 0.24' || return 1 } +# use pip cache if possible but do not store it outside of the source +# tree +# see https://pip.pypa.io/en/stable/reference/pip_install.html#caching +mkdir -p install-deps-cache +top_srcdir=$(pwd) +export XDG_CACHE_HOME=$top_srcdir/install-deps-cache + # # preload python modules so that tox can run without network access # @@ -107,7 +114,6 @@ for interpreter in python2.7 python3 ; do done find . -name tox.ini | while read ini ; do - top_srcdir=$(pwd) ( cd $(dirname $ini) require=$(ls *requirements.txt 2>/dev/null | sed -e 's/^/-r /')