[Pkg-nagios-changes] [pkg-nagios3] 09/18: Take care that /var/run/nagios3 is created at boot time

Alexander Wirt formorer at debian.org
Fri Jan 3 22:51:16 UTC 2014


This is an automated email from the git hooks/post-receive script.

formorer pushed a commit to branch master
in repository pkg-nagios3.

commit 053130c8ddd3386d58d3c98279a549e625cad7ff
Author: Alexander Wirt <formorer at debian.org>
Date:   Thu Nov 14 08:46:14 2013 +0100

    Take care that /var/run/nagios3 is created at boot time
---
 debian/nagios3-common.nagios3.init | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/debian/nagios3-common.nagios3.init b/debian/nagios3-common.nagios3.init
index 558c957..2d1979c 100644
--- a/debian/nagios3-common.nagios3.init
+++ b/debian/nagios3-common.nagios3.init
@@ -47,6 +47,16 @@ log()
   log_action_end_msg ${success:-0} "$*"
 }
 
+check_run () {
+    if [ ! -d '/var/run/nagios3' ];
+    then
+        mkdir /var/run/nagios3
+        chown nagios:nagios /var/run/nagios3
+        chmod 0750 /var/run/nagios3
+    fi  
+}
+
+
 check_started () {
 	#nagios3-core can be installed without -cgi
 	if [ -e $CGICFG ];
@@ -216,6 +226,8 @@ check() {
     $DAEMON -v $NAGIOSCFG
 }
 
+check_run
+
 case "$1" in
   start)
     log_daemon_msg "Starting $DESC" "$NAME"

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-nagios/pkg-nagios3.git



More information about the Pkg-nagios-changes mailing list