diff options
author | Jose V Beneyto <sepen@crux.nu> | 2016-02-01 10:24:39 +0100 |
---|---|---|
committer | Jose V Beneyto <sepen@crux.nu> | 2016-02-01 10:24:39 +0100 |
commit | 17bb6cc6fbb0792640a2b2635c237c3ea345fee1 (patch) | |
tree | 66ccd05554ee2a48e7b36bf4af8b13f649f15e5d /monit | |
parent | 60107b5c0f68e8b17b99418ac17803eabf3ff8cd (diff) | |
download | contrib-17bb6cc6fbb0792640a2b2635c237c3ea345fee1.tar.gz contrib-17bb6cc6fbb0792640a2b2635c237c3ea345fee1.tar.xz |
monit: updated to 5.15, fixed mandir location and improved start-script (Thanks to Juergen)
Diffstat (limited to 'monit')
-rw-r--r-- | monit/.footprint | 7 | ||||
-rw-r--r-- | monit/.md5sum | 4 | ||||
-rw-r--r-- | monit/Pkgfile | 3 | ||||
-rw-r--r-- | monit/monitd | 49 |
4 files changed, 37 insertions, 26 deletions
diff --git a/monit/.footprint b/monit/.footprint index 2d9ea6283..09bbb37d2 100644 --- a/monit/.footprint +++ b/monit/.footprint @@ -5,6 +5,7 @@ drwxr-xr-x root/root etc/rc.d/ drwxr-xr-x root/root usr/ drwxr-xr-x root/root usr/bin/ -rwxr-xr-x root/root usr/bin/monit -drwxr-xr-x root/root usr/man/ -drwxr-xr-x root/root usr/man/man1/ --rw-r--r-- root/root usr/man/man1/monit.1.gz +drwxr-xr-x root/root usr/share/ +drwxr-xr-x root/root usr/share/man/ +drwxr-xr-x root/root usr/share/man/man1/ +-rw-r--r-- root/root usr/share/man/man1/monit.1.gz diff --git a/monit/.md5sum b/monit/.md5sum index e2ab4dbc5..a53b22a61 100644 --- a/monit/.md5sum +++ b/monit/.md5sum @@ -1,2 +1,2 @@ -7902ff45eaa1303ac25f6366eff251ef monit-5.13.tar.gz -912160c1b3f72bc31cb9f91d37ae364d monitd +c723745298d7ba6d28194b9f25eba6fe monit-5.15.tar.gz +2b53a910b186b0c21306f59dc0a48f8c monitd diff --git a/monit/Pkgfile b/monit/Pkgfile index 338e10389..fd4628b69 100644 --- a/monit/Pkgfile +++ b/monit/Pkgfile @@ -5,7 +5,7 @@ # Depends on: openssl name=monit -version=5.13 +version=5.15 release=1 source=(http://mmonit.com/$name/dist/$name-$version.tar.gz \ monitd) @@ -14,7 +14,6 @@ build() { cd $name-$version ./configure --prefix=/usr \ - --mandir=/usr/man \ --sysconfdir=/etc \ --without-pam diff --git a/monit/monitd b/monit/monitd index ec190dea2..a3700ff07 100644 --- a/monit/monitd +++ b/monit/monitd @@ -3,26 +3,37 @@ # /etc/rc.d/monitd: start/stop monit daemon # -CONFIG=/etc/monitrc +SSD=/sbin/start-stop-daemon +PROG=/usr/bin/monit +PID=/var/run/monit.pid +OPTS="-c /etc/monitrc -p $PID" case $1 in - start) - /usr/bin/monit -c $CONFIG - ;; - stop) - /usr/bin/killall -q /usr/bin/monit - ;; - reload) - /usr/bin/monit -c $CONFIG reload - ;; - restart) - $0 stop - sleep 1 - $0 start - ;; - *) - echo "usage: $0 [start|stop|reload|restart]" - ;; +start) + $SSD --start --pidfile $PID --exec $PROG -- $OPTS + ;; +stop) + $SSD --stop --retry 10 --pidfile $PID + ;; +restart) + $0 stop + $0 start + ;; +reload) + $PROG $OPTS reload + ;; +status) + $SSD --status --pidfile $PID + case $? in + 0) echo "$PROG is running with pid $(cat $PID)" ;; + 1) echo "$PROG is not running but the pid file $PID exists" ;; + 3) echo "$PROG is not running" ;; + 4) echo "Unable to determine the program status" ;; + esac + ;; +*) + echo "usage: $0 [start|stop|restart|reload|status]" + ;; esac -# End of File +# End of file |