From d4992d7307e71ebdf4effb0439177e68ce8a415a Mon Sep 17 00:00:00 2001 From: nadir Date: Mon, 25 Oct 2010 15:01:24 +0200 Subject: Fix allowed_hosts typo in templates/nrpe/nrpe.cfg --- templates/nrpe/nrpe.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'templates') diff --git a/templates/nrpe/nrpe.cfg b/templates/nrpe/nrpe.cfg index 5368bc8..2ae2d71 100644 --- a/templates/nrpe/nrpe.cfg +++ b/templates/nrpe/nrpe.cfg @@ -75,7 +75,7 @@ nrpe_group=nagios <%- if nagios_nrpe_allowed_hosts.to_s.empty? then %> allowed_hosts=127.0.0.1 <%- else %> -allowed_host=127.0.0.1,<%= nagios_nrpe_allowed_hosts %> +allowed_hosts=127.0.0.1,<%= nagios_nrpe_allowed_hosts %> <%- end %> # COMMAND ARGUMENT PROCESSING -- cgit v1.2.3 From a534036c8d036275aa802f86470d67e4ee46db96 Mon Sep 17 00:00:00 2001 From: Gabriel Filion Date: Sun, 31 Jan 2016 18:19:57 -0500 Subject: parametrize nagios::nrpe the current code for configuring NRPE is still relying on global variables. This is not working at all with puppet 3.x and forward, so in order to make this code functional, we need to parametrize values that are used. --- templates/nrpe/nrpe.cfg | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'templates') diff --git a/templates/nrpe/nrpe.cfg b/templates/nrpe/nrpe.cfg index 2ae2d71..21e1ff8 100644 --- a/templates/nrpe/nrpe.cfg +++ b/templates/nrpe/nrpe.cfg @@ -16,7 +16,7 @@ # number. The file is only written if the NRPE daemon is started by the root # user and is running in standalone mode. -pid_file=<%= nagios_nrpe_pid_file %> +pid_file=<%= @pid_file %> @@ -34,10 +34,8 @@ server_port=5666 # and you do not want nrpe to bind on all interfaces. # NOTE: This option is ignored if NRPE is running under either inetd or xinetd -<%- if has_variable?("nagios_nrpe_server_address") then %> -<%- if not nagios_nrpe_server_address.to_s.empty? then %> -server_address=<%= nagios_nrpe_server_address %> -<%- end %> +<%- if not @server_address.to_s.empty? then %> +server_address=<%= @server_address %> <%- end %> @@ -72,10 +70,10 @@ nrpe_group=nagios # # NOTE: This option is ignored if NRPE is running under either inetd or xinetd -<%- if nagios_nrpe_allowed_hosts.to_s.empty? then %> +<%- if @allowed_hosts.to_s.empty? then %> allowed_hosts=127.0.0.1 <%- else %> -allowed_hosts=127.0.0.1,<%= nagios_nrpe_allowed_hosts %> +allowed_hosts=127.0.0.1,<%= @allowed_hosts %> <%- end %> # COMMAND ARGUMENT PROCESSING @@ -157,7 +155,7 @@ command_timeout=60 #include_dir= #include_dir= -include_dir=<%= nagios_nrpe_cfgdir %>/nrpe.d +include_dir=<%= @cfg_dir %>/nrpe.d -- cgit v1.2.3 From c6faaaf04cbf33db4430893b6b0eeacfc5f74776 Mon Sep 17 00:00:00 2001 From: Gabriel Filion Date: Sun, 31 Jan 2016 18:21:46 -0500 Subject: nrpe: parametrize dont_blame_nrpe This value is used in order to enable or disable arguments to nrpe commands. Since some ppl might need to enable it, we should parametrize it. --- templates/nrpe/nrpe.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'templates') diff --git a/templates/nrpe/nrpe.cfg b/templates/nrpe/nrpe.cfg index 21e1ff8..d4ad9a4 100644 --- a/templates/nrpe/nrpe.cfg +++ b/templates/nrpe/nrpe.cfg @@ -88,7 +88,7 @@ allowed_hosts=127.0.0.1,<%= @allowed_hosts %> # # Values: 0=do not allow arguments, 1=allow command arguments -dont_blame_nrpe=1 +dont_blame_nrpe=<%= @dont_blame %> # COMMAND PREFIX -- cgit v1.2.3