Topic: External PIPE to PHP script
with postfix, dovecot and I have now a problem,
I have SMS box to send information about new mail, when I do like this:
1) create second account like: firstname.lastname@example.org where is always send copy of original mail from email@example.com when mail arrived.
2) Do like in FAQ: http://iredmail.org/wiki/index.php?titl … nal.Script
- Create in main.cf
transport_maps = hash:/etc/postfix/transport
In transport I write:
In main.cf do at end of file:
external-pipe unix - n n - - pipe flags= user=vmail:vmail argv=/home/me/me.sh
In me.sh I have:
php5 -c /etc/php5/apache2/php.ini -f /var/www/newmail.php
In newmail.php I have script to send SMS, and write log to other file,
My first question is how to get data from mail like FROM, TOPIC, CONTENT (I wont to send first 50 chars of new mail as preview)
And second question, why this file dosn't wotk I mean nothing is runing this file.
No other log file is creating, but if this PHP file Was run it must be create.
In log file I have no error, and in info file I have:
status=sent (delivered via external-pipe service)
I don't understand this how delivered if this file Was not runing ?
I try to original mailbox as firstname.lastname@example.org but then file is not running too but original mail is not go to my mailbox but disappear, in logs then i have this same info about delivered via external-pipe.
Get fast and professional support from iRedMail developers: