Last active
January 1, 2016 12:59
-
-
Save grauwoelfchen/8148383 to your computer and use it in GitHub Desktop.
Openrc runscript for hubot runner script.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/sbin/runscript | |
# Distributed under the terms of the GNU General Public License v2 | |
depend() { | |
need net | |
need redis | |
# need ngircd | |
need localmount | |
} | |
start() { | |
ebegin "Starting my hubot" | |
exec sudo -u hubot /var/srv/hubot/bin/my-hubot start | |
eend $? | |
} | |
stop() { | |
ebegin "Stopping my hubot" | |
exec sudo -u hubot /var/srv/hubot/bin/my-hubot stop | |
eend $? | |
} | |
restart() { | |
stop | |
sleep 3 | |
start | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment