Recommit for updates in build 113
This commit is contained in:
@@ -226,118 +226,118 @@
|
|||||||
class confdroid_nagios::client::target (
|
class confdroid_nagios::client::target (
|
||||||
|
|
||||||
) inherits confdroid_nagios::params {
|
) inherits confdroid_nagios::params {
|
||||||
if $ng_nagios_server == $fqdn {
|
if ($ng_nagios_server == $fqdn) and ($ng_enable_target == true) {
|
||||||
if $ng_include_nrpe == true {
|
if $ng_include_nrpe == true {
|
||||||
require confdroid_nrpe
|
require confdroid_nrpe
|
||||||
|
}
|
||||||
|
|
||||||
@@nagios_host { $fqdn:
|
@@nagios_host { $fqdn:
|
||||||
ensure => $ng_ping_ensure,
|
ensure => $ng_ping_ensure,
|
||||||
alias => $hostname,
|
alias => $hostname,
|
||||||
address => $fqdn,
|
address => $fqdn,
|
||||||
use => 'linux-server',
|
use => 'linux-server',
|
||||||
target => $ng_target_host,
|
target => $ng_target_host,
|
||||||
hostgroups => 'linux-servers',
|
hostgroups => 'linux-servers',
|
||||||
contacts => $ng_contact_name,
|
contacts => $ng_contact_name,
|
||||||
max_check_attempts => $ng_max_check_attempts,
|
max_check_attempts => $ng_max_check_attempts,
|
||||||
notification_period => '24x7',
|
notification_period => '24x7',
|
||||||
owner => 'nagios',
|
owner => 'nagios',
|
||||||
group => 'nagios',
|
group => 'nagios',
|
||||||
mode => '0640',
|
mode => '0640',
|
||||||
check_command => "check_ping!${ng_ping_warn}!${ng_ping_crit}",
|
check_command => "check_ping!${ng_ping_warn}!${ng_ping_crit}",
|
||||||
notify => Service[$ng_service],
|
notify => Service[$ng_service],
|
||||||
}
|
}
|
||||||
|
|
||||||
@@nagios_service { "root_partition_${fqdn}":
|
@@nagios_service { "root_partition_${fqdn}":
|
||||||
ensure => $ng_disk_ensure,
|
ensure => $ng_disk_ensure,
|
||||||
check_command => "check_nrpe!check_disk!${ng_disk_warn}!${ng_disk_crit}!/",
|
check_command => "check_nrpe!check_disk!${ng_disk_warn}!${ng_disk_crit}!/",
|
||||||
|
use => 'generic-service',
|
||||||
|
host_name => $fqdn,
|
||||||
|
contacts => $ng_contact_name,
|
||||||
|
notification_period => '24x7',
|
||||||
|
service_description => "${fqdn}_root_partition",
|
||||||
|
servicegroups => 'linux-services',
|
||||||
|
target => $ng_target_service,
|
||||||
|
owner => 'nagios',
|
||||||
|
group => 'nagios',
|
||||||
|
mode => '0640',
|
||||||
|
}
|
||||||
|
|
||||||
|
if $ng_enable_swap_check == true {
|
||||||
|
@@nagios_service { "Swap_Usage_${fqdn}":
|
||||||
|
ensure => $ng_swap_ensure,
|
||||||
|
check_command => "check_nrpe!check_swap!${ng_swap_warn}!${ng_swap_crit}",
|
||||||
use => 'generic-service',
|
use => 'generic-service',
|
||||||
host_name => $fqdn,
|
host_name => $fqdn,
|
||||||
contacts => $ng_contact_name,
|
contacts => $ng_contact_name,
|
||||||
notification_period => '24x7',
|
notification_period => '24x7',
|
||||||
service_description => "${fqdn}_root_partition",
|
service_description => "${fqdn}_swap_usage",
|
||||||
servicegroups => 'linux-services',
|
servicegroups => 'linux-services',
|
||||||
target => $ng_target_service,
|
target => $ng_target_service,
|
||||||
owner => 'nagios',
|
owner => 'nagios',
|
||||||
group => 'nagios',
|
group => 'nagios',
|
||||||
mode => '0640',
|
mode => '0640',
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if $ng_enable_swap_check == true {
|
@@nagios_service { "Local_Users_${fqdn}":
|
||||||
@@nagios_service { "Swap_Usage_${fqdn}":
|
ensure => $ng_users_ensure,
|
||||||
ensure => $ng_swap_ensure,
|
check_command => "check_nrpe!check_users!${ng_users_warn}!${ng_users_crit}",
|
||||||
check_command => "check_nrpe!check_swap!${ng_swap_warn}!${ng_swap_crit}",
|
use => 'generic-service',
|
||||||
use => 'generic-service',
|
host_name => $fqdn,
|
||||||
host_name => $fqdn,
|
contacts => $ng_contact_name,
|
||||||
contacts => $ng_contact_name,
|
notification_period => '24x7',
|
||||||
notification_period => '24x7',
|
service_description => "${fqdn}_local_users",
|
||||||
service_description => "${fqdn}_swap_usage",
|
servicegroups => 'linux-services',
|
||||||
servicegroups => 'linux-services',
|
target => $ng_target_service,
|
||||||
target => $ng_target_service,
|
owner => 'nagios',
|
||||||
owner => 'nagios',
|
group => 'nagios',
|
||||||
group => 'nagios',
|
mode => '0640',
|
||||||
mode => '0640',
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@@nagios_service { "Local_Users_${fqdn}":
|
@@nagios_service { "Total Processes_${fqdn}":
|
||||||
ensure => $ng_users_ensure,
|
ensure => $ng_procs_tot_ens,
|
||||||
check_command => "check_nrpe!check_users!${ng_users_warn}!${ng_users_crit}",
|
check_command => "check_nrpe!check_procs!${ng_procs_tot_warn}!${ng_procs_tot_crit}!${ng_procs_tot_param}",
|
||||||
use => 'generic-service',
|
use => 'generic-service',
|
||||||
host_name => $fqdn,
|
host_name => $fqdn,
|
||||||
contacts => $ng_contact_name,
|
contacts => $ng_contact_name,
|
||||||
notification_period => '24x7',
|
notification_period => '24x7',
|
||||||
service_description => "${fqdn}_local_users",
|
service_description => "${fqdn}_total_processes",
|
||||||
servicegroups => 'linux-services',
|
servicegroups => 'linux-services',
|
||||||
target => $ng_target_service,
|
target => $ng_target_service,
|
||||||
owner => 'nagios',
|
owner => 'nagios',
|
||||||
group => 'nagios',
|
group => 'nagios',
|
||||||
mode => '0640',
|
mode => '0640',
|
||||||
}
|
}
|
||||||
|
|
||||||
@@nagios_service { "Total Processes_${fqdn}":
|
@@nagios_service { "Zombie Processes_${fqdn}":
|
||||||
ensure => $ng_procs_tot_ens,
|
ensure => $ng_procs_z_ensure,
|
||||||
check_command => "check_nrpe!check_procs!${ng_procs_tot_warn}!${ng_procs_tot_crit}!${ng_procs_tot_param}",
|
check_command => "check_nrpe!check_procs!${ng_procs_z_warn}!${ng_procs_z_crit}!${ng_procs_z_param}",
|
||||||
use => 'generic-service',
|
use => 'generic-service',
|
||||||
host_name => $fqdn,
|
host_name => $fqdn,
|
||||||
contacts => $ng_contact_name,
|
contacts => $ng_contact_name,
|
||||||
notification_period => '24x7',
|
notification_period => '24x7',
|
||||||
service_description => "${fqdn}_total_processes",
|
service_description => "${fqdn}_zombie_processes",
|
||||||
servicegroups => 'linux-services',
|
servicegroups => 'linux-services',
|
||||||
target => $ng_target_service,
|
target => $ng_target_service,
|
||||||
owner => 'nagios',
|
owner => 'nagios',
|
||||||
group => 'nagios',
|
group => 'nagios',
|
||||||
mode => '0640',
|
mode => '0640',
|
||||||
}
|
}
|
||||||
|
|
||||||
@@nagios_service { "Zombie Processes_${fqdn}":
|
@@nagios_service { "Current_Load_${fqdn}":
|
||||||
ensure => $ng_procs_z_ensure,
|
ensure => $ng_load_ensure,
|
||||||
check_command => "check_nrpe!check_procs!${ng_procs_z_warn}!${ng_procs_z_crit}!${ng_procs_z_param}",
|
check_command => "check_nrpe!check_load!${ng_load_warn}!${ng_load_crit}",
|
||||||
use => 'generic-service',
|
use => 'generic-service',
|
||||||
host_name => $fqdn,
|
host_name => $fqdn,
|
||||||
contacts => $ng_contact_name,
|
contacts => $ng_contact_name,
|
||||||
notification_period => '24x7',
|
notification_period => '24x7',
|
||||||
service_description => "${fqdn}_zombie_processes",
|
service_description => "${fqdn}_current_load",
|
||||||
servicegroups => 'linux-services',
|
servicegroups => 'linux-services',
|
||||||
target => $ng_target_service,
|
target => $ng_target_service,
|
||||||
owner => 'nagios',
|
owner => 'nagios',
|
||||||
group => 'nagios',
|
group => 'nagios',
|
||||||
mode => '0640',
|
mode => '0640',
|
||||||
}
|
|
||||||
|
|
||||||
@@nagios_service { "Current_Load_${fqdn}":
|
|
||||||
ensure => $ng_load_ensure,
|
|
||||||
check_command => "check_nrpe!check_load!${ng_load_warn}!${ng_load_crit}",
|
|
||||||
use => 'generic-service',
|
|
||||||
host_name => $fqdn,
|
|
||||||
contacts => $ng_contact_name,
|
|
||||||
notification_period => '24x7',
|
|
||||||
service_description => "${fqdn}_current_load",
|
|
||||||
servicegroups => 'linux-services',
|
|
||||||
target => $ng_target_service,
|
|
||||||
owner => 'nagios',
|
|
||||||
group => 'nagios',
|
|
||||||
mode => '0640',
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}</pre>
|
}</pre>
|
||||||
|
|||||||
@@ -955,6 +955,24 @@ inherited by all classes except defines.
|
|||||||
|
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
|
||||||
|
<span class='name'>ng_enable_target</span>
|
||||||
|
|
||||||
|
|
||||||
|
<span class='type'>(<tt>Boolean</tt>)</span>
|
||||||
|
|
||||||
|
|
||||||
|
<em class="default">(defaults to: <tt>true</tt>)</em>
|
||||||
|
|
||||||
|
|
||||||
|
—
|
||||||
|
<div class='inline'>
|
||||||
|
<p>Whether to enable the generation of host and service configuration files for the Nagios server. Default is true.</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</li>
|
||||||
|
|
||||||
<li>
|
<li>
|
||||||
|
|
||||||
<span class='name'>ng_contactgroup_members</span>
|
<span class='name'>ng_contactgroup_members</span>
|
||||||
@@ -979,8 +997,6 @@ inherited by all classes except defines.
|
|||||||
<pre class="lines">
|
<pre class="lines">
|
||||||
|
|
||||||
|
|
||||||
103
|
|
||||||
104
|
|
||||||
105
|
105
|
||||||
106
|
106
|
||||||
107
|
107
|
||||||
@@ -1150,10 +1166,13 @@ inherited by all classes except defines.
|
|||||||
271
|
271
|
||||||
272
|
272
|
||||||
273
|
273
|
||||||
274</pre>
|
274
|
||||||
|
275
|
||||||
|
276
|
||||||
|
277</pre>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<pre class="code"><span class="info file"># File 'manifests/params.pp', line 103</span>
|
<pre class="code"><span class="info file"># File 'manifests/params.pp', line 105</span>
|
||||||
|
|
||||||
class confdroid_nagios::params (
|
class confdroid_nagios::params (
|
||||||
|
|
||||||
@@ -1169,6 +1188,7 @@ class confdroid_nagios::params (
|
|||||||
String $ng_status_upd_interval = '10',
|
String $ng_status_upd_interval = '10',
|
||||||
String $ng_check_ext_commands = '1',
|
String $ng_check_ext_commands = '1',
|
||||||
String $ng_user = 'nagios',
|
String $ng_user = 'nagios',
|
||||||
|
Boolean $ng_enable_target = true,
|
||||||
|
|
||||||
# contact groups
|
# contact groups
|
||||||
String $ng_contactgroup_name = 'admins',
|
String $ng_contactgroup_name = 'admins',
|
||||||
|
|||||||
Reference in New Issue
Block a user