procmail and sendmail
Giorgos Keramidas
keramida at ceid.upatras.gr
Fri Apr 28 17:34:52 UTC 2006
On 2006-04-28 19:22, Efren Bravo <efrenba at yahoo.es> wrote:
> Giorgos Keramidas wrote:
> > If not, you need to do that, and add your local system-wide procmail
> > options or filters to `/usr/local/etc/procmailrc'.
>
> After installed the procmail, where can I find the procmailrc file
> because it's not into /usr/local/etc/ path ?
Nowhere, you create one yourself. Very very carefully, because these
rules will be applied to *all* incoming local email.
The manpage of procmail(1) explains where Procmail will look for
filtering rules:
If no rcfiles and no -p have been specified on the command line,
procmail will, prior to reading $HOME/.procmailrc, interpret
commands from /usr/local/etc/procmailrc (if present). Care must be
taken when creating /usr/local/etc/procmailrc, because, if
circumstances permit, it will be executed with root privileges
(contrary to the $HOME/.procmailrc file of course).
For example, in your system-wide `procmailrc' file you can use rules
like the following:
MAILDIR=$HOME/Mail
DEFAULT=$HOME/Mailbox
LOGABSTRACT=no
LOGFILE=$HOME/procmail.log
:0 H
* ^X-Spam-Flag: YES
spam/.
:0 H
* ^Subject: {Spam not delivered}
spam/.
:0 H
* ^Subject: {Possible Spam}
spam/.
The "/." suffix of the folder names means they are MH-style mail
folders. You can also use a plain "/" suffix for Maildir folders,
or no suffix at all for plain Unix mbox-style files.
More information about the freebsd-questions
mailing list