Created
December 9, 2013 22:21
-
-
Save signed0/7882058 to your computer and use it in GitHub Desktop.
Upstart config file for Hubot using IRC
This file contains hidden or 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
description "Hubot IRC bot" | |
# This will make Hubot start on system boot | |
start on filesystem or runlevel [2345] | |
stop on runlevel [!2345] | |
# Path to Hubot installation | |
env HUBOT_DIR='/opt/hubot/' | |
env HUBOT='bin/hubot' | |
env LOGFILE='/dev/null' | |
env ADAPTER='irc' | |
env HUBOT_USER='hubot' # system account | |
env HUBOT_NAME='hubot' # what hubot listens to | |
# IRC variables | |
env HUBOT_IRC_SERVER='127.0.0.1' | |
env HUBOT_IRC_ROOMS="#room1,#room2" | |
env HUBOT_IRC_NICK='hubot' | |
# Keep the process alive, limit to 5 restarts in 60s | |
respawn | |
respawn limit 5 60 | |
exec start-stop-daemon --start --chuid ${HUBOT_USER} --chdir ${HUBOT_DIR} \ | |
--exec ${HUBOT_DIR}${HUBOT} -- --adapter ${ADAPTER} --name ${HUBOT_NAME} >> ${LOGFILE} 2>&1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment