summaryrefslogtreecommitdiff
path: root/pcr/zoneminder-lts/zoneminder
diff options
context:
space:
mode:
authorAndré Fabian Silva Delgado <emulatorman@lavabit.com>2012-11-06 03:18:22 -0200
committerAndré Fabian Silva Delgado <emulatorman@lavabit.com>2012-11-06 03:18:22 -0200
commit8ab3c2d0517cb4db3ab2f7635d0b71b701e464ba (patch)
tree4c1cc09aa97b1eeef74104c51cba19f478e12c9a /pcr/zoneminder-lts/zoneminder
parent662bed5c46f291f040df8a2a946ed2b9caaf26b2 (diff)
parent44510ce78d8724c5a5bf1a2979618bf7825f737a (diff)
downloadabslibre-8ab3c2d0517cb4db3ab2f7635d0b71b701e464ba.tar.gz
abslibre-8ab3c2d0517cb4db3ab2f7635d0b71b701e464ba.tar.bz2
abslibre-8ab3c2d0517cb4db3ab2f7635d0b71b701e464ba.zip
Merge branch 'master' of ssh://parabolagnulinux.org:1863/srv/git/abslibre
Diffstat (limited to 'pcr/zoneminder-lts/zoneminder')
-rw-r--r--pcr/zoneminder-lts/zoneminder63
1 files changed, 63 insertions, 0 deletions
diff --git a/pcr/zoneminder-lts/zoneminder b/pcr/zoneminder-lts/zoneminder
new file mode 100644
index 000000000..c4cbf4d3f
--- /dev/null
+++ b/pcr/zoneminder-lts/zoneminder
@@ -0,0 +1,63 @@
+#!/bin/bash
+
+daemon_name=zm
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+case "$1" in
+ start)
+ stat_busy "Starting Zoneminder"
+ /usr/bin/zmfix -a
+ if /usr/bin/zmpkg.pl start >/dev/null ; then
+ add_daemon $daemon_name
+ stat_done
+ else
+ stat_fail
+ exit 1
+ fi
+ ;;
+
+ stop)
+ stat_busy "Stopping Zoneminder"
+ if /usr/bin/zmpkg.pl stop >/dev/null ; then
+ rm_daemon $daemon_name
+ stat_done
+ else
+ stat_fail
+ exit 1
+ fi
+ ;;
+
+ reload)
+ stat_busy "Reloading Zoneminder"
+ if /usr/bin/zmpkg.pl graceful >/dev/null ; then
+ add_daemon $daemon_name
+ stat_done
+ else
+ stat_fail
+ exit 1
+ fi
+ ;;
+
+ restart)
+ stat_busy "Restarting Zoneminder"
+ if /usr/bin/zmpkg.pl restart >/dev/null ; then
+ add_daemon $daemon_name
+ stat_done
+ else
+ stat_fail
+ exit 1
+ fi
+ ;;
+
+ status)
+ stat_busy "Checking Zoneminder status";
+ ck_status $daemon_name
+ ;;
+
+ *)
+ echo "usage: $0 {start|stop|reload|restart|status}"
+esac
+
+exit 0