Browse Source

Remove hardcoded mail in helo data (cosmetic fix).

Raphael Schneeberger 6 years ago
parent
commit
706e96b10f
2 changed files with 8 additions and 1 deletions
  1. 1 1
      install/deb/exim/exim4.conf.template
  2. 7 0
      install/upgrade/versions/latest.sh

+ 1 - 1
install/deb/exim/exim4.conf.template

@@ -324,7 +324,7 @@ begin transports
 
 remote_smtp:
   driver = smtp
-  helo_data = mail.${sender_address_domain}
+  helo_data = ${sender_address_domain}
   dkim_domain = DKIM_DOMAIN
   dkim_selector = mail
   dkim_private_key = DKIM_PRIVATE_KEY

+ 7 - 0
install/upgrade/versions/latest.sh

@@ -54,4 +54,11 @@ fi
 # Remove errornous history.log file created by certain builds due to bug in v-restart-system
 if [ -e $HESTIA/data/users/history.log ]; then
     rm -f $HESTIA/data/users/history.log
+fi
+
+# Use exim4 hostname without hardcoded mailprefix
+if [ ! -z "$MAIL_SYSTEM" ]; then
+    if cat /etc/exim4/exim4.conf.template | grep -q 'helo_data = mail.${sender_address_domain}'; then
+        sed -i 's/helo_data = mail.${sender_address_domain}/helo_data = ${sender_address_domain}/g' /etc/exim4/exim4.conf.template
+    fi
 fi