1
0
mirror of https://github.com/jcwimer/wrestlingApp synced 2026-03-25 01:14:43 +00:00

Easy deploy strategy

This commit is contained in:
2015-11-20 12:52:59 +00:00
parent 0e5229f2a3
commit dd05fd7eb1

22
deploy/server-deploy-prod.sh Executable file
View File

@@ -0,0 +1,22 @@
if [ -z "$1" ]
then
echo "usage) server-deploy-prod.sh user@server"
exit 1
fi
echo "Copying your ssh key to ${1}"
ssh-copy-id $1
clear
ssh -t $1 bash -c "'
cd wrestlingApp
mv deploy/prod.env ../
git pull origin master
mv ../prod.env deploy/
#Kill all containers
docker kill $(docker ps -q)
bash rails-prod.sh wrestlingdev
cd deploy
docker-compose -f docker-compose-prod.yml up -d
'"