summaryrefslogtreecommitdiff
path: root/main/zoneminder
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
parentd340da7dbce0642936c9e4b6dc4cb133bd41d72e (diff)
downloadaports-97818776efa24f66ed6f7cb868e83865a311f483.zip
main/zoneminder: always set permissions
Diffstat (limited to 'main/zoneminder')
-rw-r--r--main/zoneminder/APKBUILD5
-rw-r--r--main/zoneminder/zoneminder.initd16
2 files changed, 8 insertions, 13 deletions
diff --git a/main/zoneminder/APKBUILD b/main/zoneminder/APKBUILD
index 51667c12e6f..d615d582e81 100644
--- a/main/zoneminder/APKBUILD
+++ b/main/zoneminder/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: Kaarle Ritvanen <kaarle.ritvanen@datakunkku.fi>
pkgname=zoneminder
pkgver=1.27.0
-pkgrel=8
+pkgrel=9
pkgdesc="Video camera surveillance system"
url="http://www.zoneminder.com/"
arch="all"
@@ -67,8 +67,7 @@ package() {
ln -sf /var/lib/zoneminder/$dir \
"$pkgdir"/usr/share/webapps/zoneminder/htdocs/$dir || return 1
done
- install -m 755 -d "$pkgdir"/var/log/$pkgname \
- "$pkgdir"/var/run/$pkgname
+ install -m 755 -d "$pkgdir"/var/log/$pkgname
# create symlinks from webapps to default http location
mkdir -p "$pkgdir"/var/www/localhost/htdocs \
diff --git a/main/zoneminder/zoneminder.initd b/main/zoneminder/zoneminder.initd
index bfb32318dc3..0cecd480100 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
}