On Fri, Sep 13, 2024 at 01:31:46AM +0000, Marcus Park wrote: > I currently have 3 nodes as postfix servers. > One is the main server which accepts messages from clients via submission. > The main server routes messages out via another postfix (a or b) by the > setting of relay_host. > For now I want to route messages by sender domains. So I was asking the info > here. >
Read: http://www.postfix.org/ADDRESS_REWRITING_README.html#resolve https://www.postfix.org/postconf.5.html#sender_dependent_default_transport_maps Then: main.cf: sender_dependent_default_transport_maps = { { @a.example = smtp:[postfix-a.example] } { @b.example = smtp:[postfix-b.example] } } I am advising against use of sender_dependent_relayhost_maps, because of its much lower priority, and because you typically do not want to override the relayhost for your own "relay" domains, and only need the nexthop overrides for outbound traffic to external domains. That said, compare the docs for the two parameters, and make your own conclusions if unexpectedly your needs dictate sender-dependent nexthop selection even for you "relay" domains. -- Viktor. _______________________________________________ Postfix-users mailing list -- postfix-users@postfix.org To unsubscribe send an email to postfix-users-le...@postfix.org