summaryrefslogtreecommitdiff
path: root/scripts/deploy.sh
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/deploy.sh')
-rwxr-xr-xscripts/deploy.sh9
1 files changed, 5 insertions, 4 deletions
diff --git a/scripts/deploy.sh b/scripts/deploy.sh
index 871f11a..bd78599 100755
--- a/scripts/deploy.sh
+++ b/scripts/deploy.sh
@@ -1,5 +1,6 @@
#!/bin/bash
+DIR="$(cd "$(dirname "$0")" && pwd)"
STATUS="Status: Downloaded newer image for blindsidenetwks/scalelite:latest"
new_status=$(sudo docker pull blindsidenetwks/scalelite:latest | grep Status:)
@@ -8,10 +9,10 @@ echo $new_status
if [ "$STATUS" == "$new_status" ]
then
- cd /home/ubuntu/scalelite-run
- sudo docker-compose down
- sudo docker rmi $(sudo docker images -f dangling=true -q)
- sudo docker-compose up -d
+ cd $DIR/..
+ docker-compose down
+ docker rmi $(docker images -f dangling=true -q)
+ docker-compose up -d
fi
exit 0