Puppet Class: monitoring::params

Inherited by:
monitoring
Defined in:
manifests/params.pp

Overview

Parameters:

  • ensure (Any) (defaults to: present)
  • sms_alerts (Any) (defaults to: true)
  • notifications (Any) (defaults to: true)
  • monitoring_server (Any) (defaults to: undef)
  • monitoring_type (Any) (defaults to: undef)
  • host_name (Any) (defaults to: $::fqdn)
  • host_ip (Any) (defaults to: $::ipaddress)
  • host_groups (Any) (defaults to: undef)
  • parents (Any) (defaults to: undef)
  • host_type (Any) (defaults to: 'linux_server')
  • host_alias (Any) (defaults to: undef)
  • check_period (Any) (defaults to: undef)
  • notification_period (Any) (defaults to: undef)
  • ping_warn (Any) (defaults to: '550.0,40%')
  • ping_crit (Any) (defaults to: '750.0,70%')
  • db_server (Any) (defaults to: "db.${::domain}")
  • db_user (Any) (defaults to: 'nagios')
  • db_pass (Any) (defaults to: hiera('monitoring::db_password', undef))
  • db_port (Any) (defaults to: 3306)
  • sms_notify_script_name (Any) (defaults to: 'notify_by_clickatell')
  • sms_notify_script_template (Any) (defaults to: 'monitoring/scripts/notify_by_clickatell.pl.erb')
  • sms_host_notify_command_args (Any) (defaults to: '-a $USER7$ -u $USER8$ -p $USER9$ -n "$NOTIFICATIONTYPE$" -w "$NOTIFICATIONAUTHOR$" -c "$NOTIFICATIONCOMMENT$" -m "$NOTIFICATIONTYPE$: $HOSTNAME$ is $HOSTSTATE$ ($HOSTOUTPUT$) for $HOSTDURATION$" -t $CONTACTPAGER$')
  • sms_notify_command_args (Any) (defaults to: '-a $USER7$ -u $USER8$ -p $USER9$ -n "$NOTIFICATIONTYPE$" -w "$NOTIFICATIONAUTHOR$" -c "$NOTIFICATIONCOMMENT$" -m "$NOTIFICATIONTYPE$: $HOSTNAME$/$SERVICEDESC$ is $SERVICESTATE$ ($SERVICEOUTPUT$) for $SERVICEDURATION$" -t $CONTACTPAGER$')


2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# File 'manifests/params.pp', line 2

class monitoring::params (
  $ensure = present,
  $sms_alerts = true,
  $notifications = true,
  $monitoring_server = undef,
  $monitoring_type = undef, # ie icinga or nagios
  $host_name = $::fqdn,
  $host_ip = $::ipaddress,
  $host_groups = undef,
  $parents = undef,
  $host_type = 'linux_server',
  $host_alias = undef,
  $check_period = undef,
  $notification_period = undef,
  $ping_warn = '550.0,40%',
  $ping_crit = '750.0,70%',
  $db_server = "db.${::domain}",
  $db_user = 'nagios',
  $db_pass = hiera('monitoring::db_password', undef),
  $db_port = 3306,
  $sms_notify_script_name = 'notify_by_clickatell', # these only need to be set if sms_alerts are true
  $sms_notify_script_template = 'monitoring/scripts/notify_by_clickatell.pl.erb',
  $sms_host_notify_command_args = '-a $USER7$ -u $USER8$ -p $USER9$ -n "$NOTIFICATIONTYPE$" -w "$NOTIFICATIONAUTHOR$" -c "$NOTIFICATIONCOMMENT$" -m "$NOTIFICATIONTYPE$: $HOSTNAME$ is $HOSTSTATE$ ($HOSTOUTPUT$) for $HOSTDURATION$" -t $CONTACTPAGER$',
  $sms_notify_command_args = '-a $USER7$ -u $USER8$ -p $USER9$ -n "$NOTIFICATIONTYPE$" -w "$NOTIFICATIONAUTHOR$" -c "$NOTIFICATIONCOMMENT$" -m "$NOTIFICATIONTYPE$: $HOSTNAME$/$SERVICEDESC$ is $SERVICESTATE$ ($SERVICEOUTPUT$) for $SERVICEDURATION$" -t $CONTACTPAGER$',
) {

#  validate_re($monitoring_type, '^(icinga|nagios)$',
#  "${monitoring_type} is not supported for monitoring_type.
#  Allowed values are 'icinga' and 'nagios'.")

  $nagios_plugins = $::architecture ? {
    'x86_64' => '/usr/lib64/nagios/plugins',
    default => '/usr/lib/nagios/plugins'
  }
#  $nagios_extra_plugins = hiera('monitoring::nagios_extra_plugins', $nagios_plugins)
#  $total_procs_warn = hiera('monitoring::total_procs_warn', 250)
#  $total_procs_crit = hiera('monitoring::total_procs_crit', 300)
#  $mailq_warn = 100
#  $mailq_crit = 300
}