瀏覽代碼

Fix main.cf merging order

Now the dnsbl files are merged before extra.cf
Sébastien RICCIO 2 年之前
父節點
當前提交
5e7583c5e6
共有 1 個文件被更改,包括 4 次插入4 次删除
  1. 4 4
      data/Dockerfiles/postfix/postfix.sh

+ 4 - 4
data/Dockerfiles/postfix/postfix.sh

@@ -435,6 +435,10 @@ EOF
   fi
 fi
 
+# Append postscreen dnsbl sites to main.cf
+cat /opt/postfix/conf/dns_blocklists.cf >> /opt/postfix/conf/main.cf
+cat /tmp/spamhaus.cf >> /opt/postfix/conf/main.cf
+
 sed -i '/User overrides/q' /opt/postfix/conf/main.cf
 echo >> /opt/postfix/conf/main.cf
 touch /opt/postfix/conf/extra.cf
@@ -443,10 +447,6 @@ echo -e "myhostname = ${MAILCOW_HOSTNAME}\n$(cat /opt/postfix/conf/extra.cf)" >
 
 cat /opt/postfix/conf/extra.cf >> /opt/postfix/conf/main.cf
 
-# Append postscreen dnsbl sites to main.cf
-cat /opt/postfix/conf/dns_blocklists.cf >> /opt/postfix/conf/main.cf
-cat /tmp/spamhaus.cf >> /opt/postfix/conf/main.cf
-
 if [ ! -f /opt/postfix/conf/custom_transport.pcre ]; then
   echo "Creating dummy custom_transport.pcre"
   touch /opt/postfix/conf/custom_transport.pcre