Changing init to sourced script for python nev
This commit is contained in:
+10
-5
@@ -1,4 +1,8 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
|
# check whether script is sourced
|
||||||
|
[[ "${BASH_SOURCE[0]}" == "${0}" ]] && echo "script is executed, but needs to be sourced" && exit 1
|
||||||
|
|
||||||
echo "######################################################################################"
|
echo "######################################################################################"
|
||||||
echo "## Reinit repository"
|
echo "## Reinit repository"
|
||||||
rm -rf kubespray
|
rm -rf kubespray
|
||||||
@@ -6,11 +10,12 @@ VERSION=${1:-release-2.14}
|
|||||||
git clone --branch $VERSION https://github.com/kubernetes-sigs/kubespray.git
|
git clone --branch $VERSION https://github.com/kubernetes-sigs/kubespray.git
|
||||||
|
|
||||||
echo "######################################################################################"
|
echo "######################################################################################"
|
||||||
echo "## Activating python3 venv"
|
echo "## Activating pyenv venv"
|
||||||
VENVDIR=venv
|
eval "$(pyenv init -)"
|
||||||
virtualenv $VENVDIR
|
eval "$(pyenv virtualenv-init -)"
|
||||||
source $VENVDIR/bin/activate
|
pyenv virtualenv 3.8.3 infrapuzzle-bootstrap
|
||||||
pip install -r kubespray/requirements.txt
|
pyenv activate infrapuzzle-bootstrap
|
||||||
|
python -m pip install -r kubespray/requirements.txt
|
||||||
|
|
||||||
|
|
||||||
echo "######################################################################################"
|
echo "######################################################################################"
|
||||||
|
|||||||
Reference in New Issue
Block a user