Nagios Object Resources

July 28, 2026 ยท View on GitHub

Nagios object resources render object definitions through the shared Nagios model.

Resources

Actions

  • :create
  • :delete

Properties

  • options: hash or Chef::DataBagItem containing Nagios object options.

Examples

nagios_command 'check_http' do
  options(
    'command_line' => '$USER1$/check_http -H $HOSTADDRESS$'
  )
end

nagios_host 'web01' do
  options(
    'address' => '192.0.2.10',
    'use' => 'server'
  )
end

nagios_service 'http-web01' do
  options(
    'host_name' => 'web01',
    'service_description' => 'HTTP',
    'check_command' => 'check_http'
  )
end