Problem: You use the email system on your WHM / CPanel server to send emails, but you do not have the time or resources to ensure your server is configured properly for all the different email systems out there. Reverse DNS, SPF, DKIM etc. so your server winds up on the blacklist for hotmail, live, yahoo maybe even gmail.
If you have the time to learn and configure all these all the different pieces of the puzzle so that your server can send emails reliably, and to maintain those settings as the different email providers tighten their criteria, then great. You should offer that as a service.
I personally do not have the extra time to do it.
So what is your option.
Use a Third party service, Like Amazon SES to relay the mails for you.
If you use Exim (default mail system on WHM servers) and have root access to the server. then Amazon has documented how to setup SES as your relay server. http://docs.aws.amazon.com/ses/latest/DeveloperGuide/exim.html
The instructions are straight forward and work except for one piece. If you setup email forwarders, they will not work. Exim will use the SES server when forwarding emails, and the original sender of the email is most likely not on the approved senders list.
How I finally figured out how to get forwarders to work (not use SES) but route all other mail through SES.
From the Amazon documentation: you need to modify the router section of the instructions slightly.
send_via_ses: driver = manualroute domains = ! +local_domains transport = ses_smtp route_list = * email-smtp.us-east-1.amazonaws.com;
Modify the above section to read like this:
send_via_ses: driver = manualroute domains = !+local_domains condition = ${if !eqi{$local_part@$domain}{EMAIL_ADDRESS1}} condition = ${if !eqi{$local_part@$domain}{EMAIL_ADDRESS2}} transport = ses_smtp route_list = * email-smtp.us-east-1.amazonaws.com
Notice the 2 new lines that start with “condition”. Just replace the EMAIL_ADDRESS1 and EMAIL_ADDRESS2 with valid email addresses that your system forwards mail to.
I tried other Exim conditions, and I could not get them to work properly. But this simple approach works like a charm.
It is not dynamic, so if you add forwarders to new addresses, it will not automatically add them, you would need to copy one of the condition lines and change the email address.
If I get a chance, I am sure there is a way to make this read the list of forwarders that are setup on the server. but I just needed a quick fix and did not have time to figure out how.