I'm trying to get Postfix to pipe ALL email coming in on a specific domain to a PHP script. So far I've been able to do this via a tutorial I found on the web and also editing the /etc/postfix/virtual
file with something like what's below;
@domain.com root
The problem is that Postfix is re-writing the original recipient email address (for example my_fake_email@domain.com) to root@domain.com and the PHP script receiving the email does not get the original recipient (my_fake_email@domain.com). It is important that the PHP script sees my_fake_email@domain.com instead of root@domain.com.
Is it possible for Postfix to direct all incoming mail to the PHP script without modifying the address like in the example above?
Note: There can/will potentially be 10,000's of incoming email addresses.
Any ideas on how I can get Postfix to do what I want?