diff options
Diffstat (limited to '')
-rw-r--r-- | debian/update-libc.d | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/debian/update-libc.d b/debian/update-libc.d index 84e954b..d071430 100644 --- a/debian/update-libc.d +++ b/debian/update-libc.d @@ -1,13 +1,7 @@ -#!/bin/sh -e - -# we only need to copy this in if the service is already running. -# if it's not running, it'll get picked up by the init script on start. -/usr/sbin/service postfix status >/dev/null 2>&1 || exit 0 - -QUEUEDIR="$(/usr/sbin/postconf -hx queue_directory 2>/dev/null || true)" -if [ -n "$QUEUEDIR" ]; then - cp /etc/resolv.conf "${QUEUEDIR}/etc/resolv.conf" - /usr/sbin/service postfix reload >/dev/null 2>&1 || exit 0 +#! /bin/sh +# update postfix copy of resolv.conf; only default instance is handled +file=/etc/resolv.conf queue=/var/spool/postfix +if [ -d $queue${file%/*} ] && [ -f /etc/postfix/main.cf ] +then # just refresh, glibc pick it up automatically + [ ! -f $file ] && rm -f $queue$file || cp -pLu $file $queue$file fi - -exit 0 |