I'm trying to set up a Postfix server on Google Cloud, which blocks outgoing SMTP ports. My problem is that one email address (say [email protected]
) needs to be an alias for an external email address ([email protected]
); all emails sent to [email protected] need to be forwarded to [email protected]. I also have other email addresses that simply need to be delivered locally.
I am able to get Postfix to attempt to send all emails to [email protected] to [email protected] using virtual alias mappings, but because SMTP ports are blocked, the connection doesn't go through to example2.com's SMTP server. I want to get Postfix to send these emails through Mailjet on port 2525 so that the connection isn't blocked. Unfortunately, even when relayhost
is set to in-v3.mailjet.com:2525
, Postfix doesn't attempt to relay the emails and instead tries to send them directly.
I'm on Ubuntu 16.04.
relayhost
, notrelay_host
.