Good afternoon, dear community,
There is such problem: on the server (debian) installed apache and on it hangs a website on a certain IP (hereinafter IP2). Only on the server konfigurera 2 IP (hereinafter IP1 and IP2).
In /etc/network/interfaces eth0 is listed as IP1 and IP2 as eth0:0.
Through the website (which runs on IP2) with mail() to send mail. In the header of incoming mail contains such a line:
Received: from www-data by mail.XXXXXX.com with local (Exim 4.69),
where mail.XXXXXX.com — reverse DNS to IP1. There's also other titles featured IP1.
I need to have mail sent via IP2. And in headlines everywhere appeared IP2, not IP1. How to do it?
PS I'm not a sysadmin, and many do not know the intricacies. But what we have now — set up itself.
P. P. S. Found in Exim settings setting the System Mail Name, but there you can only specify one address it seems.