Hi Guys, I know this can be done, but I can't find it in the docs. I want an e-mail send to a particular account to run a batch file that will send the results back to another account. Any ideas or pointers please ?? Simon
On Wed, Nov 21, 2001 at 09:18:23AM -0000, Simon Parkes wrote:
Hi Guys, I know this can be done, but I can't find it in the docs. I want an e-mail send to a particular account to run a batch file that will send the results back to another account. Any ideas or pointers please ??
in /etc/aliases: someaccount: "| /usr/local/bin/someprog" Then email sent to someaccount will be piped to /usr/local/bin/someprog
On Wed, 21 Nov 2001 15:20:27 Chris Allen wrote:
On Wed, Nov 21, 2001 at 09:18:23AM -0000, Simon Parkes wrote:
Hi Guys, I know this can be done, but I can't find it in the docs. I want an e-mail send to a particular account to run a batch file that will send the results back to another account. Any ideas or pointers please ??
in /etc/aliases:
someaccount: "| /usr/local/bin/someprog"
Then email sent to someaccount will be piped to /usr/local/bin/someprog
And as for sending the results to a third account, this can be done by having the script that gets run invoke sendmail again to send the output out.
On Wed, 21 Nov 2001, Simon Parkes wrote:
Hi Guys, I know this can be done, but I can't find it in the docs. I want an e-mail send to a particular account to run a batch file that will send the results back to another account. Any ideas or pointers please ??
Simplest (non-sendmail-specific) solution is to use forward, ie in the account that receives the email put in .forward something like: \user,"| name_of_batchfile" ...which will save a copy of the email to user's account and also pipe it to the batchfile (which should then email the results). I think. I could be wrong (and probably am). Andrew. -- All views are my own .... who else would want them?
Simon Parkes wrote:
Hi Guys, I know this can be done, but I can't find it in the docs. I want an e-mail send to a particular account to run a batch file that will send the results back to another account. Any ideas or pointers please ??
Simon
I think you either need procmail for this (with sendmail, that is), or a cron job to detect, analyse and then delete the file. AFAIK, sendmail itself can't do this. But then, I may be wrong! Cheers, Laurie. -- --------------------------------------------------------------------- Laurie Brown laurie@brownowl.com PGP key at http://pgpkeys.mit.edu:11371 ---------------------------------------------------------------------
participants (5)
-
Andrew Savory -
Chris Allen -
Laurie Brown -
Simon Parkes -
Steve Fosdick