[rt-users] Tip: using procmail to guard against mail loops
Adam Hirsch
adam at baz.org
Fri Mar 5 19:35:23 EST 2004
Figured I'd share, since I got this working, and it even preserves $EXTENSION,
if you like that sort of thing:
in /etc/aliases:
###############
queue: "|/usr/bin/procmail -p -a $EXTENSION -m QUEUENAME=ops /usr/local/etc/RT.procmailrc"
queue-c: "|/usr/bin/procmail -p -a $EXTENSION -m QUEUENAME=ops /usr/local/etc/RT.procmailrc"
###############
in /usr/local/etc/RT.procmailrc:
###############
VERBOSE=no
PATH=/bin:/usr/bin:/usr/local/bin:/usr/sbin:/usr/local/sbin
UMASK=077
COMSAT=yes
FORMAIL=/usr/bin/formail
SENDMAIL=/usr/sbin/sendmail
LOGFILE=/var/tmp/proclog
:0H
* ^X-RT-Loop-Prevention: OBVIOUSLY_YOUR_SITENAME
/dev/null
:0H
* ^TO.*-c@
| /opt/rt3/bin/rt-mailgate --queue $QUEUENAME --extension ticket --action comment --url http://localhost/
:0HE
| /opt/rt3/bin/rt-mailgate --queue $QUEUENAME --extension ticket --action correspond --url http://localhost/
Adam
--
Before you start saying yuppies don't exist: they do. ... Androids who never
get jokes and who have something scared and mean at the core of their
existence, like an underfed Chihuahua baring its teeny fangs and waiting to
have its face kicked in, or like a glass of milk sloshed on top of the violet
filaments of a bug barbecue: a weird abuse of nature.
<adam at baz.org> - Douglas Coupland, in _Generation X_
More information about the rt-users
mailing list