]> git.pld-linux.org Git - packages/nagios.git/commitdiff
- improved configtest output
authorElan Ruusamäe <glen@pld-linux.org>
Sat, 25 Jul 2009 19:29:16 +0000 (19:29 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    nagios.init -> 1.21

nagios.init

index 3116508a21ed5ff2f34436228399f3d13a3ad1e8..a159c1fb6d3b3f0a497c19711cac142f1d7e3f40 100644 (file)
@@ -41,9 +41,16 @@ checkconfig() {
 
        if [ $details = 1 ]; then
                # run config test and display report (status action)
-               show "Checking %s configuration" "Nagios"; busy; echo
-               configtest
+               show "Checking %s configuration" "Nagios"; busy
+               local out
+               out=`configtest 2>&1`
                RETVAL=$?
+               if [ $RETVAL = 0 ]; then
+                       ok
+               else
+                       fail
+                       echo >&2 "$out"
+               fi
        else
                # run config test and abort with nice message if failed
                # (for actions checking status before action).
This page took 0.034008 seconds and 4 git commands to generate.