From d116de79e8a4f4177885a0a1d30610295438eadc Mon Sep 17 00:00:00 2001 From: Valentin Lab Date: Mon, 12 Apr 2021 13:52:07 +0200 Subject: [PATCH] fix: dev: [host] on debian 9, ``setuptools`` was not installed and required Signed-off-by: Valentin Lab --- precise/host/hooks/install.d/70-0k.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/precise/host/hooks/install.d/70-0k.sh b/precise/host/hooks/install.d/70-0k.sh index 47f6680..07cf6de 100755 --- a/precise/host/hooks/install.d/70-0k.sh +++ b/precise/host/hooks/install.d/70-0k.sh @@ -25,7 +25,11 @@ mkdir -p /opt/apps git checkout 0k/prod/master fi - pip install sact.epoch || exit 1 + ## Debian 9 did not have setuptool + if [ "$(python -c 'import setuptools' 2>&1 | tail -n 1)" == "ImportError: No module named setuptools" ]; then + pip install setuptools + fi + pip install sact.epoch if [ "$(python -c 'import sact.epoch' 2>&1 | tail -n 1)" == "ImportError: No module named interface" ]; then echo "Error: conflicting installation of zope.interface detected. Trying workaround." (