summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexandros Michalopoulos2019-05-17 15:06:31 +0300
committerAlexandros Michalopoulos2019-05-17 15:06:31 +0300
commit3bda197fa9b4ff26546247c01d799adeb98903cb (patch)
tree2628e7c038c6246a45bc39a6007cbbefa822da4a
parent12ff9400e65e40d3bbb2cf20a6296b2a3b6414e8 (diff)
downloadaur-3bda197fa9b4ff26546247c01d799adeb98903cb.tar.gz
v=1.32.3, r=2
-rw-r--r--.SRCINFO18
-rw-r--r--PKGBUILD32
-rw-r--r--zoneminder-httpd.conf1
-rw-r--r--zoneminder.install35
4 files changed, 46 insertions, 40 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 829dcccdc1d4..952f8be85f37 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = zoneminder
pkgdesc = A full-featured, open source, state-of-the-art video surveillance software system
pkgver = 1.32.3
- pkgrel = 1
+ pkgrel = 2
url = https://zoneminder.com/
install = zoneminder.install
arch = x86_64
@@ -10,11 +10,6 @@ pkgbase = zoneminder
depends = polkit
depends = ffmpeg
depends = libmp4v2
- depends = mariadb
- depends = nginx-mainline
- depends = fcgiwrap
- depends = spawn-fcgi
- depends = multiwatch
depends = php-apcu
depends = php-fpm
depends = php-gd
@@ -43,12 +38,17 @@ pkgbase = zoneminder
depends = perl-php-serialization
depends = perl-sys-cpu
depends = perl-uri-encode
+ depends = nginx-mainline
+ depends = fcgiwrap
+ depends = spawn-fcgi
+ depends = multiwatch
+ depends = mariadb
optdepends = apache: alternative web server
- optdepends = vlc: provides libvlc (may achieve better performance with some cameras)
- optdepends = ffmpeg-full: provides libavresample (dropped from the official ffmpeg package)
+ optdepends = vlc: provides libvlc (may achieve better performance with some camera models)
conflicts = zoneminder-git
backup = etc/nginx/sites-available/zoneminder.conf
backup = etc/httpd/conf/extra/zoneminder.conf
+ backup = etc/php/conf.d/zoneminder.ini
source = https://github.com/ZoneMinder/ZoneMinder/archive/1.32.3.tar.gz
source = https://github.com/FriendsOfCake/crud/archive/v3.2.0.tar.gz
source = https://github.com/ZoneMinder/CakePHP-Enum-Behavior/archive/1.0-zm.tar.gz
@@ -62,7 +62,7 @@ pkgbase = zoneminder
sha256sums = 55be29e1eccb44d4ad0db8b23c37cec50f5341f8e498583d472ed1f0493876e3
sha256sums = dbd231e97b950c698f0f501d6a53c7291c9985e766b09e3afe00cfe69a969f44
sha256sums = be503e5cedf42383122a1f96a6e00e25d473f8c1c536c000db748dbde12c88b0
- sha256sums = 9657fd9fdbdb4a96e3c31c9453610200258711f5ae2f6e46d3eeb9676ae857a6
+ sha256sums = 0753527da658bb4025509c03923f21f7995cedb09008d64f1568fd1d5c2ec46b
sha256sums = 479f290d3c92938cd929020ad140d613814b912b4302c2758be6446ebfb8a4ac
sha256sums = 3e4de227e3154dffa887f2286c339ab3cf456f6d74a400b2786192b7e2b129c0
sha256sums = b69ac1deaaf3cf84b4ae4dbab794e1b062823de817f1e3a816ccf5438db440c0
diff --git a/PKGBUILD b/PKGBUILD
index a035ee88f5d3..f7d49d8208b2 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -27,27 +27,22 @@
#######################################################################################################################
# #
-# If you're upgrading from a version older than 1.32.0: #
+# If you're upgrading from a release older than 1.32.0: #
# #
-# Due to the many breaking changes in this release (both upstream and in the packaging), it's recommended to backup #
+# Due to the many breaking changes in new releases (both upstream and in the packaging), it's recommended to backup #
# any existing ZoneMinder databases and perform a clean installation. Failure to do so may have very weird results. #
# #
#######################################################################################################################
-
pkgname=zoneminder
pkgver=1.32.3
-pkgrel=1
+pkgrel=2
pkgdesc='A full-featured, open source, state-of-the-art video surveillance software system'
arch=('x86_64')
url='https://zoneminder.com/'
license=('GPL2')
depends=('polkit' 'ffmpeg' 'libmp4v2'
- # Remove the following line if you want to install ZoneMinder without a local database server, e.g. as part of a Multi-Server setup
- 'mariadb'
- # Remove the following line if you don't need Nginx
- 'nginx-mainline' 'fcgiwrap' 'spawn-fcgi' 'multiwatch'
'php-apcu' 'php-fpm' 'php-gd'
'perl-archive-zip' 'perl-data-dump' 'perl-date-manip' 'perl-dbd-mysql' 'perl-device-serialport' 'perl-file-slurp' 'perl-image-info'
'perl-json-any' 'perl-libwww' 'perl-mime-lite' 'perl-mime-tools' 'perl-number-bytes-human' 'perl-sys-meminfo' 'perl-sys-mmap'
@@ -57,15 +52,24 @@ depends=('polkit' 'ffmpeg' 'libmp4v2'
'perl-lwp-protocol-https'
# Apparently needed for Telemetry support
'perl-json-maybexs'
- # Unverified dependencies. So far not installing them hasn't raised any red flags, but I can't be 100% sure whether they're leftovers from previous ZoneMinder incarnations or if they're needed for proper operation during runtime, so for the time being I'm leaving them in.
- 'perl-net-sftp-foreign' 'perl-php-serialization' 'perl-sys-cpu' 'perl-uri-encode')
+ # Unverified dependencies. So far not installing them hasn't raised any red flags, but I can't be 100% sure whether they're leftovers from
+ # previous ZoneMinder incarnations or if they're needed for proper operation during runtime, so for the time being I'm leaving them in.
+ 'perl-net-sftp-foreign' 'perl-php-serialization' 'perl-sys-cpu' 'perl-uri-encode'
+
+ # Remove the following line if you don't need Nginx
+ 'nginx-mainline' 'fcgiwrap' 'spawn-fcgi' 'multiwatch'
+
+ # Remove the following line if you don't need MariaDB
+ 'mariadb'
+
+ )
makedepends=('cmake')
optdepends=('apache: alternative web server'
- 'vlc: provides libvlc (may achieve better performance with some cameras)'
- 'ffmpeg-full: provides libavresample (dropped from the official ffmpeg package)')
+ 'vlc: provides libvlc (may achieve better performance with some camera models)')
conflicts=('zoneminder-git')
backup=("etc/nginx/sites-available/$pkgname.conf"
- "etc/httpd/conf/extra/$pkgname.conf")
+ "etc/httpd/conf/extra/$pkgname.conf"
+ "etc/php/conf.d/$pkgname.ini")
install=$pkgname.install
source=("https://github.com/ZoneMinder/ZoneMinder/archive/$pkgver.tar.gz"
"https://github.com/FriendsOfCake/crud/archive/v3.2.0.tar.gz"
@@ -82,7 +86,7 @@ sha256sums=('9a7e61c529a6269ff0344403369b160b8c8da48615c4172377c465da0b0074b1'
# zoneminder-nginx.conf
'be503e5cedf42383122a1f96a6e00e25d473f8c1c536c000db748dbde12c88b0'
# zoneminder-httpd.conf
- '9657fd9fdbdb4a96e3c31c9453610200258711f5ae2f6e46d3eeb9676ae857a6'
+ '0753527da658bb4025509c03923f21f7995cedb09008d64f1568fd1d5c2ec46b'
# zoneminder-php.ini
'479f290d3c92938cd929020ad140d613814b912b4302c2758be6446ebfb8a4ac'
# zoneminder.service
diff --git a/zoneminder-httpd.conf b/zoneminder-httpd.conf
index 450e003274a0..45ec9d93ecc2 100644
--- a/zoneminder-httpd.conf
+++ b/zoneminder-httpd.conf
@@ -1,7 +1,6 @@
Listen 8095
<VirtualHost *:8095>
- ServerName *:8095
DocumentRoot /srv/zoneminder/www
# PHP handler
diff --git a/zoneminder.install b/zoneminder.install
index d3537908e703..e96d3c15a0b6 100644
--- a/zoneminder.install
+++ b/zoneminder.install
@@ -36,7 +36,7 @@ post_install() {
echo "ERROR: Nginx was detected but file '/etc/nginx/nginx.conf' was not found. Something seems broken."
echo
fi
- # Else, if Nginx either is not installed, or is installed and inactive but Apache is also installed, we prefer Apache.
+ # Else, if Nginx either is not installed, or is installed and inactive but Apache is also installed (no matter if it's active or not), we prefer Apache.
elif [[ "$(pacman -Qs apache)" = *"local/apache"* ]]
then
# Ensure the main conf file is present
@@ -66,32 +66,36 @@ post_install() {
fi
# Else, if neither of them is installed, we inform the user that something is seriously messed up.
else
- echo "ERROR: Neither Nginx nor Apache were detected in your system. I hope you know what you're doing."
+ echo "WARNING: Neither Nginx nor Apache were detected in your system. I hope you know what you're doing."
echo
fi
### fcgiwrap ###
+ # By default fcgiwrap is configured to launch in 10 instances via spawn-fcgi and multiwatch. This should be
+ # enough for ZoneMinder to operate with 3 cameras. If you need more than 10 simultaneous CGI threads, edit the
+ # provided fcgiwrap-multiwatch.service file and increase the number of instances to whatever suits your needs.
+
if [[ "$(pacman -Qs fcgiwrap)" = *"local/fcgiwrap"* ]]
then
systemctl is-active --quiet fcgiwrap.socket && systemctl stop fcgiwrap.socket
systemctl is-active --quiet fcgiwrap && systemctl stop fcgiwrap
systemctl is-active --quiet fcgiwrap-multiwatch && systemctl stop fcgiwrap-multiwatch
- systemctl start fcgiwrap-multiwatch &&
- {
- echo "---------------"
- echo
- echo "fcgiwrap has been launched in multiple parallel instances via spawn-fcgi and multiwatch."
- echo
- echo "The default number of 10 instances should be enough for ZoneMinder to operate with 2 or 3 cameras"
- echo "under normal circumstances. If you need more than 10 simultaneous CGI threads, edit the provided"
- echo "fcgiwrap-multiwatch.service file and increase the number of instances to whatever suits your needs."
- echo
- }
+ systemctl start fcgiwrap-multiwatch
fi
### PHP-FPM ###
+ # To avoid modifying the global 'php.ini' file, this package uses a separate 'conf.d/zoneminder.ini' in order to apply
+ # some PHP settings that ZoneMinder needs to function properly, namely to load some PHP modules and to set the correct
+ # timezone.
+ #
+ # This has the side effect that any further changes to these specific PHP settings that have been overriden (i.e. to change
+ # the timezone or to disable one of the modules) will either need to be made inside 'conf.d/zoneminder.ini', or that file
+ # will have to be modified so it no longer overrides them.
+ #
+ # Modifying the global 'php.ini' on its own will have NO EFFECT as far as these settings are concerned.
+
# Set local timezone in /etc/php/conf.d/zoneminder.ini
sed -i 's|PLACEHOLDER|'`timedatectl | grep "Time zone" | tr -s ' ' | cut -f4 -d ' '`'|g' /etc/php/conf.d/zoneminder.ini
@@ -111,7 +115,6 @@ post_install() {
then
# Stop MariaDB if it's active
systemctl is-active --quiet mariadb && systemctl stop mariadb
- # NOTE: This will need to be changed when MariaDB 10.2 hits the repos, as mysql_install_db has been deprecated in favor of mysqld
mysql_install_db --user=mysql --basedir=/usr --datadir=/var/lib/mysql 2> /dev/null
fi
@@ -163,14 +166,14 @@ post_install() {
}
post_upgrade() {
- # Parse zm.conf and any custom configuration files
+ # Parse zm.conf and all custom configuration files
. /etc/zoneminder/zm.conf
for CONF in /etc/zoneminder/conf.d/*.conf; do
. $CONF
done
# Check if we're running a local database server
- if [ "$ZM_DB_HOST" = "localhost" ]; then
+ if [ "$ZM_DB_HOST" = "localhost" ] || [[ "$ZM_DB_HOST" = "127.0.0.1"* ]]; then
systemctl daemon-reload
# Make sure MariaDB is running before we attempt to use the updater