SUMMARY:How to call a script function when mail server receive an email
Alexander Surbakti
alex at indo.com
Mon Jan 17 21:14:05 EST 2005
dear all,
several days ago i sent this topic to this mailing list and i just
solved it yesterday night.
most of what i have done is like what disastermaster was told. i have a
perl file named callscript.pl that needed to be run when our mail server
get an email from a certain address, at this case the address i use is
alex at localhost. all the step that i have done is:
shell>vi /etc/aliases
#make some editing
alex : "|/etc/smrsh/callsript.pl"
#this is what disastermaster forgot to tell me that the perl file
must be placed at /etc/smrsh
shell>newaliases
and then i write mail to alex at localhost. when i check at
/var/spool/mail_log i found that stat=sent. it verified with the
increament of rows number in my mysql table since the callscript.pl
written with insert data function.
earlier the callscript.pl i placed at /var/www/cgi-bin which caused
stat=service unavailable.
have a nice day,
cheers,
-alex-
More information about the summaries
mailing list