On 19 Jul 2016, at 15:50, Ryan Coleman wrote:
strange... how do you run spamassassin from postfix?
In master.cf like everyone elseā¦
Um, not so much...
smtp inet n - - - - smtpd
-o content_filter=spamassassin
[...]
spamassassin unix - n n - - pipe
user=spamd argv=/usr/bin/spamc -f -e /usr/sbin/sendmail -oi -f
${sender} ${recipient}
FWIW, that's probably roughly the 5th most common way to integrate
Postfix and SpamAssassin. I'd guess that amavisd-new as a before-queue
filter is 1st, followed by amavisd-new as an after-queue filter,
spamass-milter, and MIMEDefang (also a milter). There are pros and cons
for every approach but a 'pipe' content_filter using spamc's '-e' option
probably has the fewest "pros" and has the problems described at
https://wiki.apache.org/spamassassin/IntegratedSpamdInPostfix. Also, you
probably want 'flags=Rq' in the pipe arguments and there is no '-f'
argument documented for spamc, so that should probably go unless you
know something the spamc man page doesn't...
A possible cause of your trouble could be spamc not knowing the correct
way to talk to spamd. In that case, the '-e' option causes spamc to
bypass spamd and just pipe its input to the given command, exiting with
a successful return code unless that command fails. This seems to match
what you're describing.