[Postfix] Fix alias for spam and ham addresses

master
André 2018-07-25 01:21:22 +02:00
parent 4d393d9265
commit ef8c79c0e5
1 changed files with 3 additions and 3 deletions

View File

@ -5,9 +5,9 @@ trap "postfix stop" EXIT
[[ ! -d /opt/postfix/conf/sql/ ]] && mkdir -p /opt/postfix/conf/sql/
cat /dev/null > /etc/aliases;
echo "null: /dev/null" >> /etc/aliases;
echo "ham: '|/usr/bin/curl -s --data-binary @- --unix-socket /rspamd-sock/rspamd.sock http://rspamd/learnham'" >> /etc/aliases;
echo "spam: '|/usr/bin/curl -s --data-binary @- --unix-socket /rspamd-sock/rspamd.sock http://rspamd/learnspam'" >> /etc/aliases;
echo 'null: /dev/null' >> /etc/aliases;
echo '"ham: "|/usr/bin/curl -s --data-binary @- --unix-socket /rspamd-sock/rspamd.sock http://rspamd/learnham"' >> /etc/aliases;
echo 'spam: "|/usr/bin/curl -s --data-binary @- --unix-socket /rspamd-sock/rspamd.sock http://rspamd/learnspam"' >> /etc/aliases;
newaliases;
cat <<EOF > /opt/postfix/conf/sql/mysql_relay_recipient_maps.cf