aboutsummarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorThom Wiggers2014-12-31 15:57:42 +0100
committerThom Wiggers2014-12-31 15:57:42 +0100
commit662f236b1fb8ee410cd2125a900af5d427ebf1d7 (patch)
tree6d26653395bb66e3efca50a2e81fee038af6e9ac
parent3094d655c4c52d86eaf272198698dbb629d5783d (diff)
downloadaur-662f236b1fb8ee410cd2125a900af5d427ebf1d7.tar.gz
stop subsonic before removing
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD2
-rw-r--r--subsonic-beta.install6
3 files changed, 8 insertions, 2 deletions
diff --git a/.SRCINFO b/.SRCINFO
index bef9eb5a3b32..7bb4c7bcd3bf 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = subsonic-beta
pkgdesc = A free, web-based media streamer and jukebox.
pkgver = 5.1.beta1
- pkgrel = 2
+ pkgrel = 3
url = http://subsonic.org/
install = subsonic-beta.install
arch = i686
diff --git a/PKGBUILD b/PKGBUILD
index b534652f367a..2e601ab7d978 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -7,7 +7,7 @@
pkgname=subsonic-beta
pkgver=5.1.beta1
-pkgrel=2
+pkgrel=3
pkgdesc="A free, web-based media streamer and jukebox."
arch=('i686' 'x86_64')
url="http://subsonic.org/"
diff --git a/subsonic-beta.install b/subsonic-beta.install
index 17140ffa32c0..fc55fa960de9 100644
--- a/subsonic-beta.install
+++ b/subsonic-beta.install
@@ -21,6 +21,12 @@ post_install() {
systemctl daemon-reload
}
+pre_remove() {
+ if [[ `systemctl is-active subsonic` == 'active' ]]; then
+ systemctl stop subsonic
+ fi
+}
+
post_remove() {
getent passwd subsonic &>/dev/null && userdel subsonic >/dev/null
getent group subsonic &>/dev/null && groupdel subsonic >/dev/null