Chris: > Hello, > > I just noticed that all my mails have somehow the main domain/hostname > in them. > Like: > > Aug 16 10:42:51 nudin3 postfix/pickup[9697]: B3150766073B: uid=33 > from=<www-data> > Aug 16 10:42:51 nudin3 postfix/cleanup[10027]: B3150766073B: > message-id=<[email protected]> > Aug 16 10:42:51 nudin3 postfix/qmgr[3040]: B3150766073B: > from=<www-data@server3>, size=10718, nrcpt=1 (queue active) > > Where as domain1.de should be domain2.de > It's just that I've set up domain1.de as the default hostname. > > How is it possible with postfix to set up the hostname as the domain > name of the virtual host? > (I run several websites on this server and therefore several mail > accounts under different domains.
The web app must specify the (envelope) sender address. If you use PHP, see the following page: http://us1.php.net/manual/en/function.mail.php [some text ommitted] additional_parameters (optional) The additional_parameters parameter can be used to pass additional flags as command line options to the program configured to be used when sending mail, as defined by the sendmail_path configuration setting. FOR EXAMPLE, THIS CAN BE USED TO SET THE ENVELOPE SENDER ADDRESS WHEN USING SENDMAIL WITH THE -f SENDMAIL OPTION. Wietse
