Jeff Greenfield asked,
| Is there a way to have /etc/procmailrc run before the lookup in
| /etc/aliases is done using sendmail (something in the sendmail.cf?) -
| The problem is that I will soon have about 1400 non-local users (all
| setup in multiple /etc/aliases type files) - and I really don't want to
| have to wrapper them all to get /etc/procmailrc parsed. Any ideas?
Being no expert here but seeing no other replies at this late hour, I'll
venture the following until someone corrects it in the morning.
/etc/aliases overrides the MDA, so the literal answer to the question in
the first two lines I quoted from Jeff is "no".
But if you can't get the cat to swallow the pill, you can empty it into its
fur and make it lick it all in. Since you're going to have 1400 entries in
/etc/aliases or other aliases files anyway, you could have every alias
expanded to a pipe:
aliasname: "|/path/to/procmail -m /etc/procmailrc aliasname"
and at the end of /etc/procmailrc, procmail can do something based on the
value of $1. The only difference [don't trust me on this point; I speak
from impressions here, not from knowledge or experience] is that procmail
will read /etc/procmailrcs as user `nobody' rather than as root.
Better answers from more knowledgable people should follow in the morning.