mirror of
https://git.myvelabs.com/docker/myvemail.git
synced 2025-12-18 07:36:18 +00:00
Update build/run/docker-entrypoint/init.d/30-postfix.sh
This commit is contained in:
parent
47b2b9d25a
commit
6dacac1ad0
1 changed files with 11 additions and 4 deletions
|
|
@ -33,7 +33,7 @@ fi
|
||||||
# Whitelist Primary and Backup mail servers
|
# Whitelist Primary and Backup mail servers
|
||||||
addmx=(${MYVEMAIL_DOMAIN})
|
addmx=(${MYVEMAIL_DOMAIN})
|
||||||
addmx+=(${MYVEMAIL_ADDMX//,/ })
|
addmx+=(${MYVEMAIL_ADDMX//,/ })
|
||||||
echo -n | tee /etc/postfix/{helo_access,whitelist_{domains,emails},blacklist_{domains,emails}} >/dev/null
|
echo -n | tee /etc/postfix/{helo_access,{whitelist,blacklist}_{domains,emails}} >/dev/null
|
||||||
for domain in ${addmx[@]}
|
for domain in ${addmx[@]}
|
||||||
do
|
do
|
||||||
echo "${domain} OK Primary and backup mail servers" | tee -a /etc/postfix/helo_access >/dev/null
|
echo "${domain} OK Primary and backup mail servers" | tee -a /etc/postfix/helo_access >/dev/null
|
||||||
|
|
@ -92,9 +92,16 @@ setfacl -R -m u:postfix:rx /etc/postfix/sql/
|
||||||
|
|
||||||
# Start postfix
|
# Start postfix
|
||||||
postfix start
|
postfix start
|
||||||
|
|
||||||
|
# Create postfix db tables
|
||||||
postmap /etc/postfix/helo_access \
|
postmap /etc/postfix/helo_access \
|
||||||
/etc/postfix/whitelisted_domains /etc/postfix/whitelisted_emails \
|
|
||||||
/etc/postfix/blacklisted_domains /etc/postfix/blacklisted_emails \
|
|
||||||
/etc/postfix/smtp_header_checks /etc/postfix/header_checks \
|
/etc/postfix/smtp_header_checks /etc/postfix/header_checks \
|
||||||
/etc/postfix/body_checks \
|
/etc/postfix/body_checks \
|
||||||
/etc/postfix/postscreen_access.cidr
|
/etc/postfix/postscreen_access.cidr
|
||||||
|
for map in /etc/postfix/{helo_access,{whitelist,blacklist}_{domains,emails}}
|
||||||
|
do
|
||||||
|
if [ -s ${map} ]
|
||||||
|
then
|
||||||
|
postmap ${map}
|
||||||
|
fi
|
||||||
|
done
|
||||||
Loading…
Add table
Add a link
Reference in a new issue