troubleshooting service
This commit is contained in:
@@ -34,10 +34,14 @@ INSTALLATION
|
|||||||
|
|
||||||
CONFIGURATION
|
CONFIGURATION
|
||||||
* manage NRPE service user properties
|
* manage NRPE service user properties
|
||||||
* manage directory structure (file system permissions, selinux context)
|
* manage directory structure (file system permissions, selinux context) through parameters
|
||||||
*
|
* manage configuration files through parameters:
|
||||||
|
* nrpe.conf
|
||||||
|
* nrpe.cfg
|
||||||
|
* manage iptables (optionals )
|
||||||
|
|
||||||
SERVICE
|
SERVICE
|
||||||
|
* manage NRPE service
|
||||||
|
|
||||||
### Repo Structure
|
### Repo Structure
|
||||||
Repostructure has moved to REPOSTRUCTURE.md in repo.
|
Repostructure has moved to REPOSTRUCTURE.md in repo.
|
||||||
@@ -46,6 +50,7 @@ Repostructure has moved to REPOSTRUCTURE.md in repo.
|
|||||||
All dependencies must be included in the catalogue.
|
All dependencies must be included in the catalogue.
|
||||||
|
|
||||||
* [cd_resources](https://gitlab.puppetsoft.com/12WW1160/cd_resources) to manage YUM repositories.
|
* [cd_resources](https://gitlab.puppetsoft.com/12WW1160/cd_resources) to manage YUM repositories.
|
||||||
|
* [cd_firewall](https://gitlab.puppetsoft.com/12WW1160/cd_firewall) or [puppetlabs firewall](https://github.com/puppetlabs/puppetlabs-firewall) to manage iptables
|
||||||
* [cd_stdlib](https://gitlab.puppetsoft.com/12WW1160/cd_stdlib) or [puppetlabs stdlib](https://github.com/puppetlabs/puppetlabs-stdlib) to facilitate concat
|
* [cd_stdlib](https://gitlab.puppetsoft.com/12WW1160/cd_stdlib) or [puppetlabs stdlib](https://github.com/puppetlabs/puppetlabs-stdlib) to facilitate concat
|
||||||
* [cd_concat](https://gitlab.puppetsoft.com/12WW1160/cd_stdlib) or [puppetlabs concat](https://github.com/puppetlabs/puppetlabs-concat) for concatenating files
|
* [cd_concat](https://gitlab.puppetsoft.com/12WW1160/cd_stdlib) or [puppetlabs concat](https://github.com/puppetlabs/puppetlabs-concat) for concatenating files
|
||||||
|
|
||||||
|
|||||||
@@ -26,6 +26,8 @@ class cd_nrpe::main::files (
|
|||||||
|
|
||||||
require cd_nrpe::main::dirs
|
require cd_nrpe::main::dirs
|
||||||
|
|
||||||
|
# manage /etc/nagios/nrpe.cfg
|
||||||
|
|
||||||
file { $ne_main_conf_file:
|
file { $ne_main_conf_file:
|
||||||
ensure => file,
|
ensure => file,
|
||||||
path => $ne_main_conf_file,
|
path => $ne_main_conf_file,
|
||||||
@@ -36,6 +38,22 @@ class cd_nrpe::main::files (
|
|||||||
selrole => object_r,
|
selrole => object_r,
|
||||||
seltype => nrpe_etc_t,
|
seltype => nrpe_etc_t,
|
||||||
seluser => system_u,
|
seluser => system_u,
|
||||||
|
content => template($ne_main_conf_erb),
|
||||||
|
notify => Service[$ne_service],
|
||||||
|
}
|
||||||
|
|
||||||
|
# manage /etc/sysconfig/nrpe
|
||||||
|
|
||||||
|
file { $ne_nrpe_conf_file:
|
||||||
|
ensure => file,
|
||||||
|
path => $ne_nrpe_conf_file,
|
||||||
|
owner => 'root',
|
||||||
|
group => 'root',
|
||||||
|
mode => '0640',
|
||||||
|
selrange => s0,
|
||||||
|
selrole => object_r,
|
||||||
|
seltype => etc_t,
|
||||||
|
seluser => system_u,
|
||||||
content => template($ne_nrpe_conf_erb),
|
content => template($ne_nrpe_conf_erb),
|
||||||
notify => Service[$ne_service],
|
notify => Service[$ne_service],
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ class cd_nrpe::main::service (
|
|||||||
require cd_nrpe::firewall::iptables
|
require cd_nrpe::firewall::iptables
|
||||||
}
|
}
|
||||||
|
|
||||||
require cd_nrpe::main::files
|
require cd_nrpe::main::install
|
||||||
|
|
||||||
service { $ne_service:
|
service { $ne_service:
|
||||||
ensure => running,
|
ensure => running,
|
||||||
|
|||||||
@@ -122,7 +122,7 @@ $ne_ssl_cert_file = "/etc/pki/tls/certs/${::fqdn}.crt.pem",
|
|||||||
$ne_ssl_privatekey_file = "/etc/pki/tls/private/${::fqdn}.key.pem",
|
$ne_ssl_privatekey_file = "/etc/pki/tls/private/${::fqdn}.key.pem",
|
||||||
$ne_ssl_client_certs = '2',
|
$ne_ssl_client_certs = '2',
|
||||||
$ne_ssl_logging = '0x00',
|
$ne_ssl_logging = '0x00',
|
||||||
$ne_nasty_metachars = '\"|`&><\'\\[]{};\r\n\"',
|
$ne_nasty_metachars = '"|`&><\'\\[]{};\r\n\"',
|
||||||
$ne_include_file = '',
|
$ne_include_file = '',
|
||||||
|
|
||||||
# nrpe.conf
|
# nrpe.conf
|
||||||
@@ -152,8 +152,10 @@ $ne_run_dir = '/var/run/nrpe'
|
|||||||
|
|
||||||
# files
|
# files
|
||||||
$ne_main_conf_file = '/etc/nagios/nrpe.cfg'
|
$ne_main_conf_file = '/etc/nagios/nrpe.cfg'
|
||||||
$ne_nrpe_conf_erb = 'cd_nrpe/nrpe_cfg.erb'
|
$ne_main_conf_erb = 'cd_nrpe/nrpe_cfg.erb'
|
||||||
$ne_nrpe_pid_file = "${ne_run_dir}/nrpe.pid"
|
$ne_nrpe_pid_file = "${ne_run_dir}/nrpe.pid"
|
||||||
|
$ne_nrpe_conf_file = '/etc/sysconfig/nrpe'
|
||||||
|
$ne_nrpe_conf_erb = 'cd_nrpe/nrpe_conf.erb'
|
||||||
|
|
||||||
# includes must be last
|
# includes must be last
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user