Postfix Hide hostnames and subdomains from your relay

So your setting up a mail relay or mail agent and your want to strip off the hostname or subdomain before the message gets to the internet:  for example your relay gets it as but you want it to look like  well this is really simple with postfix.   Just load up your and add the following line

masquerade_domains =

This will strip off everything after  You can add additional domain by placing spaces between hosts.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.