mirror of https://github.com/Icinga/icinga2.git
Fix wrong nscp path w/ command_endpoint runtime macros
Do not allow to override the nscp path by runtime macros. This causes the (linux) master to send just "." as $nscp_path$ and the windows client ignores the local global constant NscpPath being overridden by the master. Only happens with command_endpoints where runtime macros are passed from the master to the clients. fixes #9456
This commit is contained in:
parent
5c11eb8b47
commit
9e663eea4b
|
@ -1051,7 +1051,6 @@ Custom attributes passed as [command parameters](3-monitoring-basics.md#command-
|
|||
|
||||
Name | Description
|
||||
----------------|--------------
|
||||
nscp_path | **Optional.** Can be used to override the NSClient++ on a per-command basis. Defaults to NscpPath.
|
||||
nscp_log_level | **Optional.** The log level. Defaults to "critical".
|
||||
nscp_load_all | **Optional.** Whether to load all modules. Defaults to true.
|
||||
nscp_boot | **Optional.** Whether to use the --boot option. Defaults to true.
|
||||
|
|
|
@ -24,7 +24,7 @@ if (!globals.contains("NscpPath")) {
|
|||
object CheckCommand "nscp-local" {
|
||||
import "plugin-check-command"
|
||||
|
||||
command = [ "$nscp_path$\\nscp.exe", "client" ]
|
||||
command = [ NscpPath + "\\nscp.exe", "client" ]
|
||||
|
||||
arguments = {
|
||||
"--log" = "$nscp_log_level$"
|
||||
|
@ -39,7 +39,6 @@ object CheckCommand "nscp-local" {
|
|||
"-a" = "$nscp_arguments$"
|
||||
}
|
||||
|
||||
vars.nscp_path = {{ NscpPath }}
|
||||
vars.nscp_log_level = "critical"
|
||||
vars.nscp_load_all = true
|
||||
vars.nscp_boot = true
|
||||
|
|
Loading…
Reference in New Issue