[Dovecot] deliver exit codes?
Before switching to dovecot deliver for all local deliveries, I'm calling deliver from maildrop (yes, don't laugh).
Snippet from my global /etc/maildroprc:
# Store maillist & junk messages directly /^Precedence: ?list/ if ( $MATCH ) { exception { log "Bulk message: $MATCH" #to "$DEFAULT" to "|$DELIVER" } }
I replaced to "$DEFAULT" (meaning: delivery to $HOME/Maildir) with to "|$DELIVER" (meaning: pipe the mail into dovecot deliver, and deliver to INBOX = $HOME/Maildir)
This works really well, UNLESS a user exceeds his/her quota: In that particular case, deliver fails to deliver the mail and generates a bounce, all on it's own.
It's exit status is 0 in that case, so my MTA (postfix) thinks that the mail has been delivered successfully.
I'd prefer deliver to return EX_TEMPFAIL, which I can pass through maildrop back to postfix, which will then log a temporary error and will bounce the mail all by itself after 5 days time.
But how?
-- Ralf Hildebrandt (Ralf.Hildebrandt@charite.de) plonk@charite.de Postfix - Einrichtung, Betrieb und Wartung Tel. +49 (0)30-450 570-155 http://www.arschkrebs.de The Imperial Vendor or Contractor probably told them that droid armies don't need redundant command centers, nor any kind of high availability ... you're supposed to buy several, and cluster them. Redundant Array of Inexpensive Droids?
On Thu, 2007-05-17 at 23:38 +0200, Ralf Hildebrandt wrote:
This works really well, UNLESS a user exceeds his/her quota: In that particular case, deliver fails to deliver the mail and generates a bounce, all on it's own.
It's exit status is 0 in that case, so my MTA (postfix) thinks that the mail has been delivered successfully.
I'd prefer deliver to return EX_TEMPFAIL, which I can pass through maildrop back to postfix, which will then log a temporary error and will bounce the mail all by itself after 5 days time.
CVS HEAD has a new quota_full_tempmail setting for this. But since you probably don't want to use CVS HEAD, your only choice is to modify the sources:
src/deliver/deliver.c line 708-709:
if (temporary_error)
return EX_TEMPFAIL;
Change that to simply:
return EX_TEMPFAIL;
participants (2)
-
Ralf Hildebrandt
-
Timo Sirainen