File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed
Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change 5858
5959# Use exim4 server hostname instead of mail domain and remove hardcoded mail prefix
6060if [ ! -z " $MAIL_SYSTEM " ]; then
61+ echo " (*) Updating exim configuration..."
6162 if cat /etc/exim4/exim4.conf.template | grep -q ' helo_data = mail.${sender_address_domain}' ; then
62- echo " (*) Updating exim configuration..."
6363 sed -i ' s/helo_data = mail.${sender_address_domain}/helo_data = ${primary_hostname}/g' /etc/exim4/exim4.conf.template
6464 fi
65+ if ! grep -q ' ^OUTGOING_IP = /' /etc/exim4/exim4.conf.template; then
66+ sed -i ' /^OUTGOING_IP/d' /etc/exim4/exim4.conf.template
67+ sed -i ' s|^begin acl|OUTGOING_IP = /etc/exim4/domains/$sender_address_domain/ip\nbegin acl|' /etc/exim4/exim4.conf.template
68+ fi
69+ if ! grep -q ' interface =' /etc/exim4/exim4.conf.template; then
70+ sed -i ' /interface =/d' /etc/exim4/exim4.conf.template
71+ sed -i ' s|dkim_strict = 0|dkim_strict = 0\n interface = ${if exists{OUTGOING_IP}{${readfile{OUTGOING_IP}}}}|' /etc/exim4/exim4.conf.template
72+ fi
6573fi
6674
6775# Members of admin group should be permitted to enter admin folder
You can’t perform that action at this time.
0 commit comments