Skip to content

sous-chefs/nrpe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

529 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

nrpe cookbook

Cookbook Version Build Status OpenCollective OpenCollective License

Chef cookbook to install Nagios NRPE client (was previously part of the Nagios cookbook)

This cookbook is a custom-resource cookbook. Legacy recipes and node attributes have been removed; see migration.md for migration examples.

Maintainers

This cookbook is maintained by the Sous Chefs. The Sous Chefs are a community of Chef cookbook maintainers working together to maintain important cookbooks. If you’d like to know more please visit sous-chefs.org or come chat with us on the Chef Community Slack in #sous-chefs.

Requirements

Chef

Chef 15.3+

Platform

  • Debian
  • FreeBSD
  • Ubuntu
  • RHEL including CentOS and Oracle Linux
  • Amazon Linux (2.x cannot be installed via package)
  • Fedora
  • SUSE / openSUSE

Notes: This cookbook has been tested on the listed platforms. It may work on other platforms with or without modification.

Resources

nrpe

Installs NRPE from packages or source, installs plugins, renders server configuration, manages allowed hosts, and enables/starts the service.

nrpe 'default' do
  allowed_hosts %w(192.0.2.10)
end

nrpe_check

The check resource provides an easy way to add and remove NRPE checks from within cookbooks.

Actions

  • :add creates a NRPE configuration file and reloads the NRPE process. Default action.
  • :remove removes the configuration file and reloads the NRPE process

Properties

  • command_name The name of the check. This is the command that you will call from your nagios_service data bag check
  • warning_condition String that you will pass to the command with the -w flag
  • critical_condition String that you will pass to the command with the -c flag
  • command The actual command to execute (including the path). If this is not specified, this will use plugin_dir/command_name as the path to the command.
  • parameters Any additional parameters you wish to pass to the plugin.
  • template Use the specific erb template to render NRPE config command.

Examples

# Use resource to define check_load
nrpe_check "check_load" do
  command '/usr/lib/nagios/plugins/check_load'
  warning_condition '10'
  critical_condition '15'
  action :add
end
# Remove the check_load definition
nrpe_check "check_load" do
  action :remove
end

Using template:

nrpe_check "check_load" do
  template "check_load.cfg.erb"
  action :add
end

Contributors

This project exists thanks to all the people who contribute.

Backers

Thank you to all our backers!

https://opencollective.com/sous-chefs#backers

Sponsors

Support this project by becoming a sponsor. Your logo will show up here with a link to your website.

https://opencollective.com/sous-chefs/sponsor/0/website https://opencollective.com/sous-chefs/sponsor/1/website https://opencollective.com/sous-chefs/sponsor/2/website https://opencollective.com/sous-chefs/sponsor/3/website https://opencollective.com/sous-chefs/sponsor/4/website https://opencollective.com/sous-chefs/sponsor/5/website https://opencollective.com/sous-chefs/sponsor/6/website https://opencollective.com/sous-chefs/sponsor/7/website https://opencollective.com/sous-chefs/sponsor/8/website https://opencollective.com/sous-chefs/sponsor/9/website

Sponsor this project

Packages

 
 
 

Contributors