aboutsummaryrefslogtreecommitdiffstats
path: root/main/zoneminder/zoneminder.initd
diff options
context:
space:
mode:
authorCarlo Landmeter <clandmeter@gmail.com>2014-06-25 20:06:50 +0200
committerCarlo Landmeter <clandmeter@gmail.com>2014-06-25 20:07:04 +0200
commit97818776efa24f66ed6f7cb868e83865a311f483 (patch)
tree0a2401e81594df8c5b339c44b24171a71c560c0b /main/zoneminder/zoneminder.initd
parentd340da7dbce0642936c9e4b6dc4cb133bd41d72e (diff)
downloadaports-97818776efa24f66ed6f7cb868e83865a311f483.tar.bz2
aports-97818776efa24f66ed6f7cb868e83865a311f483.tar.xz
main/zoneminder: always set permissions
Diffstat (limited to 'main/zoneminder/zoneminder.initd')
-rw-r--r--main/zoneminder/zoneminder.initd16
1 files changed, 6 insertions, 10 deletions
diff --git a/main/zoneminder/zoneminder.initd b/main/zoneminder/zoneminder.initd
index bfb32318dc..0cecd48010 100644
--- a/main/zoneminder/zoneminder.initd
+++ b/main/zoneminder/zoneminder.initd
@@ -5,7 +5,7 @@
name=zoneminder
command=/usr/bin/zmpkg.pl
-extra_commands="setup perms"
+extra_commands="setup"
depend() {
after mysql
@@ -16,7 +16,7 @@ start() {
if status > /dev/null; then
ewarn "$name already started"
else
- mkrundir
+ prepare
$command start
fi
eend $?
@@ -46,15 +46,11 @@ setup() {
eend $?
}
-perms() {
- . /etc/zm.conf
- ebegin "Setting correct permissions"
- chown -R $ZM_WEB_USER:$ZM_WEB_GROUP \
- /var/*/zoneminder
-}
-
-mkrundir() {
+prepare() {
. /etc/zm.conf
install -d -o $ZM_WEB_USER -g $ZM_WEB_GROUP \
/var/run/zoneminder
+ chown $ZM_WEB_USER:$ZM_WEB_GROUP \
+ /var/lib/zoneminder/* \
+ /var/log/zoneminder
}