Procmail (oder Alternative)
Stefan Ulrich Hegner
stefan at hegner-online.de
Wed Jan 7 19:19:38 CET 2004
Moin,
Nutze derzeit für Mail Postfix + amavisd + SpamAssassin + Maildir.
Bin grade dabei mit dem ca-bot zu spielen. Für den User "cabot" will ich
alle (mit fetchmail eingesammelte) Mail an ein Script pipen.
Das ginge theoretisch wunderbar mit Procmail. - Aber außer für diesen
einen User brauche ich das eigentlich gar nicht.
Gibt es eine andere (einfachere?) Alternative, das gleiche zu erreichen?
Ich hab' grad mal ein procmail installiert. Nur bevor ich die ganzen
Configs auf meinem Produktivsystem anpacke, will ich wissen was ich tue
(oder besser lasse).
Ich sehe im Moment 4 Dinge, die ich anpacken müßte:
1. in der Postfix main.cf
mailbox_command = /pfad/zu/procmail
2. in der main.cf steht dazu aber noch eine Warnung:
# IF YOU USE THIS TO DELIVER MAIL SYSTEM-WIDE, YOU MUST SET UP AN
# ALIAS THAT FORWARDS MAIL FOR ROOT TO A REAL USER.
... was auch immer das praktisch heißt.
3. in der /etc/procmailrc das ganze auf Maildir abstimmen. Geht das mit
DEFAULT=$HOME/.maildir (statt DEFAULT=/var/spool/mail/$LOGNAME)
Die Procmail-Doku schreibt aber noch:
However, if you are going to install procmail as the integrated local
delivery agent, and you want mail to be delivered to, say, $HOME/.mail
by default, this is what you have to do:
Edit the procmail*/config.h file. Uncomment and possibly
change
the SYSTEM_MBOX define. Procmail now delivers there by default.
In order to make sure that normal mailtools can find the new
system mailboxes, you should make sure that every user has the
MAIL environment variable set to be equal to whatever you
defined SYSTEM_MBOX to be. Some braindamaged mail programs
do not pick up the MAIL environment variable, these either
have to be patched/recompiled or you have to create symbolic
links in /usr/mail to every person's new mailbox.
Das macht mich _sehr_ stutzig ....
4. die ~/.procmailrc für den User "cabot"
... für mich hört sich das alles so an, als ob das noch irgendwie
einfacher gehen müßte.
Krieg ich die mail aus ~/.maildir/new/* nicht irgendwie anders an mein
script gepiped und aus dem .maildir Bereich entfernt? - Für sowas müßte
es doch sicher sowas wie mutt-Makros geben, oder ...?
Bin auf Eure Ideen gespannt!
Stefan.
--
/ Stefan Ulrich Hegner aka "Hegi" - Loehne/ Westfalen - Germany \
| stefan at hegner-online.de, my Cyberhome http://www.hegner-web.de|
\ GPG-Fprint D9DB 51BD 2DA6 9B3A 41CB 0287 05A1 8D11 38BA CE91 /
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Dies ist ein digital signierter Nachrichtenteil
URL: <http://lug-owl.de/pipermail/linux/attachments/20040107/5f839ade/attachment.sig>
More information about the Linux
mailing list