procmail
[Top] [All Lists]

Re: Forwarding messages based on BODY

2001-08-18 00:32:21
Ok I found a good page to get me started.

http://www.stimpy.net/procmail/tutorial/

Here is what I have so far that worked.

:0c B
* TEST
test

:0a
!user(_at_)domain(_dot_)com

This copied the message to a folder called test and forwarded the message to
an email address.

How would I specify additional email addresses? Can I perhaps point to a
file that contained a list of email addresses to email to?

Also if I am going to create one procmail file to detect any of the message
bodies how do I tell it that if it matches one of them to not test the
others? I found that the a tells it to run it if it matched the previous
test.

Now the above just forwards what it received. How do I go about sending a
differnet message then what was sent or adding additional text to the
message?

Thanks in advance.

Jim




----- Original Message -----
From: <jscott(_at_)infoconex(_dot_)com>
To: <procmail(_at_)Lists(_dot_)RWTH-Aachen(_dot_)DE>
Sent: Friday, August 17, 2001 10:46 PM
Subject: Forwarding messages based on BODY


I am new to Linux and just discovering procmail. I have been told that I
might be able to achieve what I need done with procmail.

Wondering if someone might be able to point me in the right direction and
perhaps supply me with some examples of how to achive this.

We have a device that sends out fairly generic emails to one email box. We
want to based on the message in the body then forward that message on to
certain individuals.

For example the body would contain simple messages like.

Utility Power down
Generator Offline
UPS Failed
PLC Test failed

So lets say a message comes into an email box with Utility power down. I
would want to forward that message to 2 people.

If I receive PLC test failed I would perhaps want to send to those 2 plus
another.

Since the message in the body is fairly simple I might even want to change
the message being sent to something more detailed.

Is this possible with procmail? Can anyone help me get started.

Thanks
Jim


_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail


_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>