Minimalistic deployment shell script.
The script consists of two side:
- Server side
- Client side
You need gcc (GNU Compiler Collection):
$ gcc -o deploy deploy.c
$ chown root.root deploy
$ chmod +s deploy
Copy example.com.sh file with your project name
$ cp example.com.sh yoursite.com.sh
You need edit file
$ vi yoursite.com.sh
Add your commands
For example:
cd /var/www/example.com
git fetch --all
git reset --hard origin/master
/var/www/example.com/bin/python3.5 src/manage.py collectstatic
supervisorctl restart example
Only need to wake another script on server
$ bash deploy.sh
1.0.0
MIT
If you want something done right, you have to do it yourself.