summaryrefslogtreecommitdiff
path: root/manifests/irc_bot.pp
blob: 7629b947a2f12d2841951acda26ae644ce8cf1d4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
class nagios::irc_bot {
  if ( ! ($nagios_nsa_server and $nagios_nsa_nickname and $nagios_nsa_channel) ) {
    fail("Please provide values at least for \$nagios_nsa_server, \$nagios_nsa_nickname and \$nagios_nsa_channel")
  }

  case $operatingsystem {
    centos: {
      $nagios_nsa_default_socket = '/var/run/nagios-nsa/nsa.socket'
      $nagios_nsa_default_pidfile = '/var/run/nagios-nsa/nsa.pid'
      include nagios::irc_bot::centos
    }
    default: {
      $nagios_nsa_default_socket = '/var/run/nagios3/nsa.socket'
      $nagios_nsa_default_pidfile = '/var/run/nagios3/nsa.pid'
      include nagios::irc_bot::base
    }
  }

  if $use_shorewall {
    include shorewall::rules::out::irc
  }
}