We use Google Apps, so the only way we use postfix is to send notification emails, like password restore, newsletters and etc. We have 3 domains, for example aaa.com, bbb.com and ccc.com.
Each service always sending email on behalf of firstname.lastname@example.org, email@example.com, etc.
How to configure postfix to set correct sender header?
Right now message header contains:
Received: from localhost (localhost [127.0.0.1]) by freebsd.boxxy.de (Postfix) with ESMTP id A650F6882 for <firstname.lastname@example.org>; Sat, 6 Nov 2010 05:29:12 +0300
If I set myhostname in main.cf to domain aaa.com, then messages sent from bbb.com would be from aaa.com, is it possible to retrieve domain from sender email and use that domain configuration?