Last Updated: February 25, 2016
·
993
· 29decibel

Sample hubot script file for hipchat adapter

# hubot

description "hubot -- a hipchat robot for the team"

start on filesystem or runlevel [2345]
stop on runlevel [!2345]

# Path to Hubot installation
env HUBOT_DIR='/home/someuser/hubot'
env HUBOT='/bin/hubot'
env ADAPTER='hipchat'

# Name (and local user) to run Hubot as
env HUBOT_USER='someuser'
env HUBOT_NAME='cutebot'

# Hipchat-specific environment variables
env HUBOT_HIPCHAT_JID=''
env HUBOT_HIPCHAT_NAME=''
env HUBOT_HIPCHAT_PASSWORD=''

# 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} -- --name ${HUBOT_NAME} --adapter ${ADAPTER} >> /var/log/moebot.log 2>&1