Hi, Setting up inbound connector in EOP is easy enough. But the outgoing relay is a bit difficult. I either have to do relayhost=microsoftsoutboundconnectordomain or use ISPConfig3's email routing. Both solutions have issues. relayhost causes all emails on system to go via outbound connector (unecessary especially when having websites and stuff that send normal emails). I only wish to use the outbound connectors for users with an EOP license. Now, if I use email routing. The outgoing emails are correct BUT incoming mail to a user on the domain I setup to route to the outbound connector also get sent out again. Essentially causing a loop since postfix -> microsoft EOP -> back to postfix -> repeat (5 or 6 times until it gives up) How can I make it so that the email routing doesn't pass emails on to the external connector for incoming emails? Only from local users and outwards. Thanks in advance
I have solved this for now by using Code: sender_dependent_relayhost_maps = hash:/etc/postfix/relayhost_maps in /etc/postfix/main.cf and setting up a postmap:ed file with @domain.com relayhostaddress.com Can ISPconfig 3 do something similar in the interface ? (so it's kept between updates)
Awesome that's good to know. But would you recommend that I use sender_dependent_relayhost_maps for this sort of use case? I dont want to cause mail loops, and allow local delivery and incoming external mails. Only when external outgoing emails for this specific domain is when I want to send it to EOP.
You can use sender_dependet_relayhost_maps. This will relay mails from @domain.com to your relayhost - even if they are created local. Maybe you need some auth before the relay-server accepts the mails.