Added local install option.

This commit is contained in:
yohan 2020-04-14 18:37:43 +02:00
parent 07f4b88431
commit 0de35b6733

View File

@ -14,6 +14,8 @@ do
{ echo "ERROR: could not create network ${NETWORK}, exiting."; exit 1; }
done
if test -z "$1" || [ "$1" != "local" ]
then
test -f ~/openrc.sh || { echo "ERROR: ~/openrc.sh not found, exiting."; exit 1; }
source ~/openrc.sh
export OS_REGION_NAME=GRA
@ -42,7 +44,13 @@ done
unset VERSION_PROXY
cd ~/build/docker-reverse-proxy; export VERSION_PROXY=$(git show-ref --head| head -1 | cut -f 1|cut -c -10)
cd $SCRIPTPATH
else
unset VERSION_PROXY
export VERSION_PROXY=$(git ls-remote https://git.scimetis.net/yohan/docker-reverse-proxy.git| head -1 | cut -f 1|cut -c -10)
rm -rf ~/build
mkdir -p ~/build
git clone https://git.scimetis.net/yohan/docker-reverse-proxy.git ~/build/docker-reverse-proxy
fi
sudo docker build -t reverse-proxy:$VERSION_PROXY ~/build/docker-reverse-proxy
sudo -E bash -c 'docker-compose up --no-start --force-recreate'