The link0/nrpe module installs, configures and manages the NRPE service.
Basic usage accepting all defaults (installation, configuration, managing the service, etcetera)
include ::nrpeAlthough, if you would like to have more control over the service, you can pass parameters like this:
class { '::nrpe':
package_ensure => latest,
service_manage => false,
}These settings can also be overridden by using Hiera
nrpe::service_manage: falseThis module is all about defining commands to be called remotely.
# This command creates '/etc/nagios/nrpe.d/check_apt.cfg' with the content:
# command[check_apt]=/usr/lib/nagios/plugins/check_apt
nrpe::command { 'check_apt':
}If you want to add arguments, those can be defined as well
# This command creates '/etc/nagios/nrpe.d/check_procs.cfg' with the content:
# command[check_procs]=/usr/lib/nagios/plugins/check_procs -w 175 -c 200
nrpe::command { 'check_procs':
arguments => '-w 175 -c 200',
}You can even specify a custom command, but keep the name NRPE calls
# This command creates '/etc/nagios/nrpe.d/check_foo.cfg' with the content:
# command[check_foo]=/usr/bin/foo -w bar -c baz
nrpe::command { 'check_foo':
command => '/usr/bin/foo',
arguments => '-w bar -c baz',
}Whether the package should be managed by puppet. Type: boolean. Defaults to true
eg package_manage: false will not install the package from your package manager
If the package is managed, how to ensure the package, Type: installed, absent or latest. Defaults to installed
If the package is available under a different name, you can specify it here. Type: string Defaults to nagios-nrpe-server
Whether you want puppet to manage the service. Type: boolean, defaults to true
If the service is managed by puppet, what should be ensured. Type: running or stopped. Defaults to running
If the service is managed by puppet, what the name of the service should be. Type: string Defaults to 'nagios-nrpe-server'.
Whether you want puppet to manage nrpe.cfg. Type: boolean, defaults to true
If the configuration is managed by puppet, which file should be managed. Type: absolute_path. Defaults to /etc/nagios/nrpe.cfg
If the configuration is managed by puppet, which template should be used. Type: string. Defaults to nrpe/nrpe.cfg.erb
Which hosts are allowed to connect to NRPE. Type: array. Defaults to ['127.0.0.1'].
Which port should NRPE be listening on. Type: integer. Defaults to 5666.
Which user should NRPE be running under. Type: string. Defaults to nagios.
Which group should NRPE be running under. Type: string. Defaults to nagios.
Which file should be used to store the PID. Type absolute_path. Defaults to /var/run/nagios/nrpe.pid.
Which log facility should NRPE be logging to. Type: string. Defaults to daemon.
What timeout should be set for commands. Type: integer. Defaults to 60.
What timeout should be set for connection issues. Type: integer. Defaults to 300.
Should NRPE be logging debug output. Type: boolean. Defaults to false.