summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGabriel Filion <lelutin@gmail.com>2011-07-14 05:25:13 -0400
committerGabriel Filion <lelutin@gmail.com>2011-07-14 05:25:13 -0400
commit131ec46d082787e79a7e4bb08ff984886c439fa5 (patch)
tree5a7b4e5deb7b7a308685a062549d359bb35c554d
parentcde75b06b4484f705218c2ef28d49ff545d75f84 (diff)
IRC-bot: cleanup socket file on startup
It may sometimes happen that the bot dies or gets killed and the socket file is not cleaned up. When using the init script with 'start', as puppet does, the socket file blocks the bot from starting.
-rw-r--r--templates/irc_bot/Debian/nagios-nsa.sh.erb1
1 files changed, 1 insertions, 0 deletions
diff --git a/templates/irc_bot/Debian/nagios-nsa.sh.erb b/templates/irc_bot/Debian/nagios-nsa.sh.erb
index 6e608db..7de660d 100644
--- a/templates/irc_bot/Debian/nagios-nsa.sh.erb
+++ b/templates/irc_bot/Debian/nagios-nsa.sh.erb
@@ -51,6 +51,7 @@ cleanup() {
case $1
in
start)
+ cleanup
start
;;
stop)