In this scenario lets pretend Postfix or another mail server is not available to relay email for me.
[server 1] <---> <dynamic IP address> <---> <internet> <---> <static ip address <---> [remote server] <internet> <---> <destination email server>
Issue: To save myself 100 dollars a month at home on static IP addresses (thanks comcast), I have setup my home network using static IP addresses. I have a remote VPS that I use that has static IPs and I use it as a router of sorts. It works GREAT for everything but for sending email. My email server is located behind my home network (server 1) and can receive email no problem, but sometimes when I send email I get a bounce back because I'm behind a dynamic IP address (some email servers reject this as possible spam).
I would like to know if there is an easy solution just using either IPTables forwarding, or SSH tunnles, or a mix?
It's easy for me to grab all traffic heading out with destination 25 and redirect it to any port on my remote VPS box, but I'm not sure how to get it to route through after that and be forwarded to the destination, such as mail.google.com or what-have-you?
Thanks for any help!