When I send a mail via php mail then postfix rewrites the from address like this.
The from becomes: username@myhosthame
How can I stop this from happening? I want postfix to preserve the from address.
Super User is a question and answer site for computer enthusiasts and power users. It only takes a minute to sign up.Sign up to join this community
To fix the domain, you have to set the
myorigin paramater in
main.cf. It defaults to
As to why the user is rewritten, by default
local_recipient_maps is set to only allow mail from users with an account on the machine, or a defined alias. From
local_recipient_maps = proxy:unix:passwd.byname $alias_maps