mirror of
https://github.com/michelleDeko/scalelite-run.git
synced 2026-02-05 15:50:54 +01:00
Added script for auto-deployment
This commit is contained in:
17
scripts/deploy.sh
Executable file
17
scripts/deploy.sh
Executable file
@@ -0,0 +1,17 @@
|
||||
#!/bin/bash
|
||||
|
||||
STATUS="Status: Downloaded newer image for blindsidenetwks/scalelite:master"
|
||||
|
||||
new_status=$(sudo docker pull blindsidenetwks/scalelite:master | grep Status:)
|
||||
|
||||
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
|
||||
fi
|
||||
|
||||
exit 0
|
||||
Reference in New Issue
Block a user