From: Michael Prokop Date: Wed, 11 Jul 2007 19:32:07 +0000 (+0200) Subject: grml-hostname: adjust mydestination as well in /etc/postfix/main.cf X-Git-Tag: 1.0.9 X-Git-Url: http://git.grml.org/?p=grml-scripts-core.git;a=commitdiff_plain;h=8db36e3a919463523f02e9504b255b3b48938657 grml-hostname: adjust mydestination as well in /etc/postfix/main.cf --- diff --git a/debian/changelog b/debian/changelog index d013d03..fa90776 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +grml-scripts (1.0.9) unstable; urgency=low + + * grml-hostname: adjust mydestination as well in /etc/postfix/main.cf. + + -- Michael Prokop Wed, 11 Jul 2007 21:31:52 +0200 + grml-scripts (1.0.8) unstable; urgency=low * cpufreq-detect.sh: merge in code from /etc/init.d/loadcpufreq for diff --git a/usr_sbin/grml-hostname b/usr_sbin/grml-hostname index 644b798..c844a44 100755 --- a/usr_sbin/grml-hostname +++ b/usr_sbin/grml-hostname @@ -43,6 +43,7 @@ case $retval in sed -i "s/^::1[ \t]*ip6-localhost ip6-loopback[ \t]*$OLDHOSTNAME/::1 ip6-localhost ip6-loopback $HOSTNAME/" /etc/hosts POSTFIX='' if [ -r /etc/postfix/main.cf ] ; then + sed -i "s/^mydestination = .*/mydestination = $HOSTNAME, localhost, localhost.localdomain/" /etc/postfix/main.cf && \ sed -i "s/^myhostname = .*/myhostname = $HOSTNAME/" /etc/postfix/main.cf && POSTFIX=' Configuration of myhostname in /etc/postfix/main.cf has been adjusted as well. Do not forget to restart postfix if necessary.' fi