Skip to content

Instantly share code, notes, and snippets.

@polds
Created February 4, 2014 21:03
Show Gist options
  • Save polds/8812329 to your computer and use it in GitHub Desktop.
Save polds/8812329 to your computer and use it in GitHub Desktop.
#!/bin/bash
#
# *************************************************
# chkconfig: 2345 99 99
# description: auto-start our deploy script on reboot
# *************************************************
#
# Installation:
# 1. save as /etc/rc.d/init.d/deploy
# 2. chmod a+x /etc/rc.d/init.d/deploy
# 3. /sbin/chkconfig --level 2345 deploy on
PATH=/bin:/usr/sbin:/usr/bin
case $1 in
start)
cd /var/deploy
screen -d -m -S DEPLOY ./deploy
;;
esac
exit 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment