summaryrefslogtreecommitdiffstats
path: root/abs/core-testing/zoneminder/zoneminder.install
diff options
context:
space:
mode:
Diffstat (limited to 'abs/core-testing/zoneminder/zoneminder.install')
-rw-r--r--abs/core-testing/zoneminder/zoneminder.install40
1 files changed, 8 insertions, 32 deletions
diff --git a/abs/core-testing/zoneminder/zoneminder.install b/abs/core-testing/zoneminder/zoneminder.install
index 27ba60a..1f3cfc0 100644
--- a/abs/core-testing/zoneminder/zoneminder.install
+++ b/abs/core-testing/zoneminder/zoneminder.install
@@ -7,46 +7,20 @@ pre_install() {
## arg 1: the new package version
post_install() {
-chown nobody.nobody /home/httpd/html/zm/events
-chown nobody.nobody /home/httpd/html/zm/images
-chown nobody.nobody /home/httpd/html/zm/temp
-chown nobody.nobody /etc/zm.conf
+chown http.http /data/srv/httpd/htdocs/zm/events
+chown http.http /data/srv/httpd/htdocs/zm/images
+chown http.http /data/srv/httpd/htdocs/zm/temp
+chown http.http /etc/zm.conf
cat << EOF
Note:
-==> Edit /etc/zm.conf to define a user and password for
+==> mythtv has been defined in /etc/zm.conf as user and password for
==> The zoneminder (zm) database
==> To initialize the ZoneMinder database run (as root)
==> /usr/lib/zm/bin/zminit
EOF
-cat /etc/php/php.ini |grep "^extension=mysql.so" >/dev/null || cat << EOF
-==> You must edit /etc/php/php.ini and uncomment "extension=mysql.so"
-==> so php and MySQL can play together.
-
-EOF
-cat /etc/php/php.ini |grep "^short_open_tag = On" >/dev/null || cat << EOF
-==> You must edit /etc/php/php.ini and set short_open_tag = On
-==> or ZoneMinder will not work
-
-EOF
-
-
-cat /etc/php/php.ini |grep "^open_basedir.*/etc/" >/dev/null || cat << EOF
-==> You must edit /etc/php/php.ini and add to it open_basedir "/etc/" as such:
-==> open_basedir = /home/:/tmp/:/usr/share/pear/:/etc/
-==> Otherwise ZoneMinder will be unable to read /etc/zm.conf
-
-EOF
-
-cat /etc/httpd/conf/httpd.conf |grep "^LoadModule php" >/dev/null || cat << EOF
-Note:
-==> You must edit /etc/httpd/conf/httpd.conf and uncomment the line
-==> #LoadModule php5_module modules/libphp5.so
-
-EOF
-
cat /etc/sysctl.conf |grep "kernel.shmall" >/dev/null || cat << EOF
==> To raise the limit on shared memory for zoneminder
==> add these lines to /etc/sysctl.conf
@@ -78,7 +52,8 @@ post_upgrade() {
# Reuse the old config
[ -f /etc/zm.conf.pacnew ] && cat /etc/zm.conf | sed -e "s/^ZM_VERSION=.*$/ZM_VERSION=1.23.3/" > /tmp/zm.conf
[ -f /etc/zm.conf.pacsave ] && cat /etc/zm.conf.pacsave | sed -e "s/^ZM_VERSION=.*$/ZM_VERSION=1.23.3/" > /tmp/zm.conf
-[ -f /tmp/zm.conf ] && mv -f /tmp/zm.conf /etc/zm.conf && chown -R nobody.nobody /etc/zm.conf
+[ -f /tmp/zm.conf ] && mv -f /tmp/zm.conf /etc/zm.conf && chown -R http.http /etc/zm.conf
+add_service.sh zm
}
## arg 1: the old package version
pre_remove() {
@@ -88,6 +63,7 @@ pre_remove() {
## arg 1: the old package version
post_remove() {
echo
+ remove_service.sh zm
}
# vim:set ts=2 sw=2 et: