Le 26 janv. 2015 à 05:31, Joseph Tam jtam.home@gmail.com a écrit :
St?phane Cottin writes:
dspam already send errors to syslog, the point here is to never loose email contents. This was a wrong design, i'm now use a wrapper instead ( see my previous post for details ).
You're stilling going to lose contents. If dspam fails, the mail is dumped, the LDA returns exit code 75, and the MTA will probably issue a bounce Email to the sender.
from dovecot-lda man page :
75 A temporary failure. This is returned for almost all failures. See the log file for details. (EX_TEMPFAIL)
The mta keep the mail and retry delivery later, which is what I need.
If you really don't want the recipient to lose Email, you should buffer the input into a file, run dspam on it, and if the output is not-null, pipe it to dovecot-lda, otherwise pipe the original input.
I don't want to deliver email on dspam error, I prefer TEMPFAIL and future retries, so I have a chance to fix the issue later without loosing or deliver unprocessed mails
Joseph Tam jtam.home@gmail.com