You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 15, 2019. It is now read-only.
Steve Traylen
Add support for sysconfig environment variables to Nagios
This patch adds a conditional source'ing of /etc/sysconfig/nagios
to the daemon start script. This is useful to set environment
variables passed on to Nagios and the plugins it runs, such as
ORACLE_LOCATION and other similar things that some plugins need
to run properly.
If Debian et al do things differently, I'm sure their package
managers can patch this appropriately.
diff --git a/daemon-init.in b/daemon-init.in
index cdb9b93..98f35e5 100644 (file)
--- a/daemon-init.in
+++ b/daemon-init.in
@@ -28,7 +28,12 @@
# Description: Starts and stops the Nagios monitor
# used to provide network services status.
#
-
+
+# Load any extra environment variables for Nagios and its plugins
+if test -f /etc/sysconfig/nagios; then
+ . /etc/sysconfig/nagios
+fi
+
status_nagios ()
{
Updated by mfriedrich on 2010-05-16 17:14:11 +00:00
so to speak a configure option, that takes e.g. --with-rhel-init or --with-debian-init and then taking the correct init script on building the init script?
This issue has been migrated from Redmine: https://dev.icinga.com/issues/387
Created by mfriedrich on 2010-04-30 20:35:50 +00:00
Assignee: (none)
Status: Closed (closed on 2010-05-19 09:24:31 +00:00)
Target Version: (none)
Last Update: 2010-05-19 09:24:31 +00:00 (in Redmine)
Depends wether on the operating system afaik. Needs to be tested though.
This one's just for RHEL, for Debian it's another location in /etc/default/
http://git.op5.org/git/?p=nagios.git;a=commit;h=155692866180682cc4515c160dcb6748a1b3fedb
Changesets
2010-05-19 09:19:17 +00:00 by Meier 4e99d93
2010-05-19 09:46:36 +00:00 by Meier e290d8d
The text was updated successfully, but these errors were encountered: