summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD8
-rw-r--r--milter-greylist.install14
-rw-r--r--milter-greylist.service3
4 files changed, 9 insertions, 20 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 83f8ab364fd..ed7f303fd83 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = milter-greylist
pkgdesc = A stand-alone milter written in C that implements the greylist filtering method.
pkgver = 4.6.2
- pkgrel = 1
+ pkgrel = 2
url = http://hcpnet.free.fr/milter-greylist/
arch = x86_64
arch = i686
@@ -15,7 +15,7 @@ pkgbase = milter-greylist
source = milter-greylist.service
md5sums = 8872008db2fc6b93dd9ab8576383fec2
md5sums = 6965cbd37d0af10d4d2e74ce8cf25095
- md5sums = 53d576fdb2150fa2940f4989a40f80d2
+ md5sums = f63fdee8f12aa6cc4e0badeb874cf565
pkgname = milter-greylist
diff --git a/PKGBUILD b/PKGBUILD
index 1b65ba5d2a1..36e11d93929 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
# Contributor: Steven Hiscocks <steven[at]hiscocks[dot]me[dot]uk>
pkgname=milter-greylist
pkgver=4.6.2
-pkgrel=1
+pkgrel=2
pkgdesc="A stand-alone milter written in C that implements the greylist filtering method."
url="http://hcpnet.free.fr/milter-greylist/"
arch=('x86_64' 'i686')
@@ -15,7 +15,7 @@ source=("http://ftp.espci.fr/pub/${pkgname}/${pkgname}-${pkgver}.tgz"
"${pkgname}.service")
md5sums=('8872008db2fc6b93dd9ab8576383fec2'
'6965cbd37d0af10d4d2e74ce8cf25095'
- '53d576fdb2150fa2940f4989a40f80d2')
+ 'f63fdee8f12aa6cc4e0badeb874cf565')
prepare() {
cd "${srcdir}/${pkgname}-${pkgver}"
@@ -32,6 +32,10 @@ package() {
cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m0644 greylist2.conf "${pkgdir}/etc/mail/greylist.conf"
+ sed -i -e 's,#dumpfile .*,dumpfile "/var/lib/milter-greylist/greylist.db",g' \
+ -e 's,#socket .*,socket "/var/lib/milter-greylist/greylist.sock",g' \
+ -e 's,#user .*,user "milt-gl:milt-gl",g' \
+ "${pkgdir}/etc/mail/greylist.conf"
install -Dm0644 "${srcdir}/${pkgname}.service" "${pkgdir}/usr/lib/systemd/system/${pkgname}.service"
echo "u milt-gl - - /var/lib/milter-greylist" | install -Dm644 /dev/stdin "${pkgdir}/usr/lib/sysusers.d/${pkgname}.conf"
echo "d /var/lib/milter-greylist 0750 milt-gl milt-gl" | install -Dm644 /dev/stdin "${pkgdir}/usr/lib/tmpfiles.d/${pkgname}.conf"
diff --git a/milter-greylist.install b/milter-greylist.install
deleted file mode 100644
index 629bd9ba393..00000000000
--- a/milter-greylist.install
+++ /dev/null
@@ -1,14 +0,0 @@
-setup_user() {
- getent group milt-gl &>/dev/null || groupadd -r milt-gl >/dev/null
- getent passwd milt-gl &>/dev/null || useradd -r -d /var/lib/milter-greylist -g milt-gl -s /sbin/nologin milt-gl >/dev/null
-
- if [[ -d /var/lib/milter-greylist ]]; then
- chown milt-gl:milt-gl /var/lib/milter-greylist
- fi
-
- true
-}
-
-post_install() {
- setup_user
-}
diff --git a/milter-greylist.service b/milter-greylist.service
index 2738e0f3332..61addb3bf5b 100644
--- a/milter-greylist.service
+++ b/milter-greylist.service
@@ -5,8 +5,7 @@ After=network.target
[Service]
UMask=0007
-Environment=SOCKET=/var/lib/milter-greylist/greylist.sock
-ExecStart=/usr/bin/milter-greylist -D -d /var/lib/milter-greylist/greylist.db -f /etc/mail/greylist.conf -u milt-gl:milt-gl -p $SOCKET
+ExecStart=/usr/bin/milter-greylist -D
[Install]
WantedBy=multi-user.target