diff options
Diffstat (limited to 'network/postgrey/rc.postgrey')
-rw-r--r-- | network/postgrey/rc.postgrey | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/network/postgrey/rc.postgrey b/network/postgrey/rc.postgrey index d763884bfa7c..5c33151085e6 100644 --- a/network/postgrey/rc.postgrey +++ b/network/postgrey/rc.postgrey @@ -1,17 +1,15 @@ #!/bin/bash -PORT=10025 -PIDFILE=/var/run/postgrey/postgrey.pid -USER=%POSTGREYUSR% -GROUP=%POSTGREYGRP% -HOST=mail.example.com +. /etc/postgrey.conf || exit 1 postgrey_start() { echo "Starting postgrey milter: /usr/bin/postgrey -d --inet=$PORT --pidfile=$PIDFILE --user=$USER --group=$GROUP --dbdir=/var/lib/postgrey --hostname=$HOST" - mkdir -p /var/run/postgrey + mkdir -p $(dirname $PIDFILE) + chown ${USER}:${GROUP} $(dirname $PIDFILE) + /usr/bin/postgrey -d \ --inet=$PORT \ - --pidfile=/var/run/postgrey/postgrey.pid \ + --pidfile=$PIDFILE \ --user=$USER --group=$GROUP \ --dbdir=/var/lib/postgrey \ --hostname=$HOST |