Skip explicit libcloud preinstall when not using a fork.
authorTom Clegg <tclegg@veritasgenetics.com>
Wed, 25 Apr 2018 17:30:27 +0000 (13:30 -0400)
committerTom Clegg <tclegg@veritasgenetics.com>
Thu, 3 May 2018 19:19:12 +0000 (15:19 -0400)
Arvados-DCO-1.1-Signed-off-by: Tom Clegg <tclegg@veritasgenetics.com>

build/libcloud-pin.sh
build/run-tests.sh

index 63f65ada8b19382e3940199bc9ce7841fc2a14b2..cfbba404504e3b7c60d553040fb64c97e3698f77 100644 (file)
@@ -3,3 +3,10 @@
 # SPDX-License-Identifier: AGPL-3.0
 
 LIBCLOUD_PIN=2.3.0
+
+using_fork=false
+if [[ $using_fork = true ]]; then
+    LIBCLOUD_PIN_SRC="https://github.com/curoverse/libcloud/archive/apache-libcloud-$LIBCLOUD_PIN.zip"
+else
+    LIBCLOUD_PIN_SRC=""
+fi
index 50a74a641677116a2d5ba9f644796833d1fd1d60..a835af3ebe14fc52506e32f960535e524c69f39f 100755 (executable)
@@ -543,11 +543,13 @@ pip freeze 2>/dev/null | egrep ^PyYAML= \
     || pip install --no-cache-dir PyYAML >/dev/null \
     || fatal "pip install PyYAML failed"
 
-# Preinstall libcloud, because nodemanager "pip install"
-# won't pick it up by default.
-pip freeze 2>/dev/null | egrep ^apache-libcloud==$LIBCLOUD_PIN \
-    || pip install --pre --ignore-installed --no-cache-dir apache-libcloud>=$LIBCLOUD_PIN >/dev/null \
-    || fatal "pip install apache-libcloud failed"
+# Preinstall libcloud if using a fork; otherwise nodemanager "pip
+# install" won't pick it up by default.
+if [[ -n "$LIBCLOUD_PIN_SRC" ]]; then
+    pip freeze 2>/dev/null | egrep ^apache-libcloud==$LIBCLOUD_PIN \
+        || pip install --pre --ignore-installed --no-cache-dir "$LIBCLOUD_PIN_SRC" >/dev/null \
+        || fatal "pip install apache-libcloud failed"
+fi
 
 # Deactivate Python 2 virtualenv
 deactivate