# HG changeset patch # User Pascal Bellard # Date 1218214023 0 # Node ID 0945fbc429576c80b93a5ae8f86441cdadc959df # Parent f4d0133065941436e75daa3af41b4cfec047ee6e postfix: set default localhost diff -r f4d013306594 -r 0945fbc42957 postfix/receipt --- a/postfix/receipt Fri Aug 08 16:14:12 2008 +0000 +++ b/postfix/receipt Fri Aug 08 16:47:03 2008 +0000 @@ -33,6 +33,19 @@ cp -a $_pkg/etc $fs awk 'BEGIN {n=0} /MUST/ {n++} /ALIASES/ {n++} { if (n==1) print }' \ < $_pkg/etc/postfix/aliases > $fs/etc/postfix/aliases + while read keyword data; do + grep -q ^$keyword $fs/etc/postfix/main.cf && continue + mv $fs/etc/postfix/main.cf $fs/etc/postfix/main.cf.$$ + awk "BEGIN { scan=1 } /^#$keyword / { if (scan) { print \"$keyword $data\" ; scan=0 } } { print }" \ + < $fs/etc/postfix/main.cf.$$ > $fs/etc/postfix/main.cf + rm -f $fs/etc/postfix/main.cf.$$ + done << EOF +mydomain = localdomain +myorigin = localhost +mydestination = localhost, localhost.\$mydomain +mynetworks = 127.0.0.0/8 +alias_maps = hash:/etc/postfix/aliases +EOF cp -a stuff/etc $fs cp -a $_pkg/var $fs mv $fs/etc/postfix/TLS_LICENSE $fs/usr/share/licenses/POSTFIX_TLS_LICENSE