Merge branch '16601-new-tutorial' refs #16601
[arvados.git] / tools / arvbox / lib / arvbox / docker / service / sdk / run-service
index 0e937908e8116f5984c367e4cee25fb718b3f833..1ec225ca128c60c2587ebcd950a7661f1ce4aa12 100755 (executable)
@@ -18,6 +18,8 @@ cd /usr/src/arvados/sdk/cli
 run_bundler --binstubs=$PWD/binstubs
 ln -sf /usr/src/arvados/sdk/cli/binstubs/arv /usr/local/bin/arv
 
+export PYCMD=python3
+
 # Need to install the upstream version of pip because the python-pip package
 # shipped with Debian 9 is patched to change behavior in a way that breaks our
 # use case.
@@ -28,18 +30,20 @@ ln -sf /usr/src/arvados/sdk/cli/binstubs/arv /usr/local/bin/arv
 # multiple packages, because it will blindly install the latest version of each
 # dependency requested by each package, even if a compatible package version is
 # already installed.
-pip_install pip
+if ! pip3 install --no-index --find-links /var/lib/pip pip==9.0.3 ; then
+    pip3 install pip==9.0.3
+fi
 
 pip_install wheel
 
 cd /usr/src/arvados/sdk/python
-python setup.py sdist
+$PYCMD setup.py sdist
 pip_install $(ls dist/arvados-python-client-*.tar.gz | tail -n1)
 
 cd /usr/src/arvados/services/fuse
-python setup.py sdist
+$PYCMD setup.py sdist
 pip_install $(ls dist/arvados_fuse-*.tar.gz | tail -n1)
 
 cd /usr/src/arvados/sdk/cwl
-python setup.py sdist
+$PYCMD setup.py sdist
 pip_install $(ls dist/arvados-cwl-runner-*.tar.gz | tail -n1)