Advanced Email Forwarding Options

Noah Dolph 10 ár síðan updated by Rodger Cravens 9 ár síðan 3
It would be great if the options for email forwarding were expanded a bit. A bit cpanel style would be great, specify either forward to an address or pipe, and then give options for the path of the pipe and the bin file to call. IE

Pipe to -> /some/path/to/script.php
Application -> php54
Options -> -q

Or something of that nature?
Actually... I guess I need the ability to add aliases. I can't modify the exim config file though as Ajenti automatically sets it up? Currently adding the pipe to the forwarder spot in Ajenti does not complete the pipe.

Found this for setting up piping...

First, browse to your Exim directory:
cd /etc/exim

Then create a directory to store your virtual hosts:
mkdir vhosts

Navigate to that directory:
cd vhosts

Then create a text file for your domain:
nano your_domain.com

Type in (replace "*" with an e-mail address
if you only want to handle e-mail to a certain
e-mail address with your handler):
*: |php -q /home/phpshare/public_html/handler.php

Save the file and exit.

Next, edit the configuration file for Exim
nano /usr/exim/configure

Change the domain list line to:
domainlist local_domains = @:localhost:dsearch;/etc/exim/vhosts

Type the following above "system_aliases:":
driver = redirect
domains = dsearch;/etc/exim/vhosts
data = ${expand:${lookup{$local_part}lsearch*@{/etc/exim/vhosts/$domain}}}
pipe_transport = address_pipe
file_transport = address_file

In addition, add or change "address_pipe:" to:
driver = pipe

Save the configuration file and exit.

Then restart Exim / Sendmail:
/etc/init.d/exim restart
/etc/init.d/sendmail restart
Disregard this, I'm retarded......
What was the final solution? I am assuming that the forwarding solution worked? I am getting ready to test that exact thing - so it was of interest to see what your solution was.