On Mon, Jul 15, 2024 at 14:49:21 +0100, Adam Weremczuk wrote: > I want to achieve the first objective and the values are static. > I just hoped there is a one liner hack (like A records in /etc/hosts) to > achieve this vs reconfiguring my MTA.
Routing Internet email in the absence of functioning DNS is going to require configuration of your MTA. So, the next question is *which* MTA you're using. I'm most familiar with qmail. I'm guessing you're not using qmail (just based on the odds), but in qmail, this would be done by creating an smtproutes file in the control directory. If you want qmail to route outgoing remote messages for @example.com to the host zeus.home.arpa, you would put this line in smtproutes: example.com:zeus.home.arpa This suppresses the normal MX lookup. The hostname zeus.home.arpa will need to be resolvable, of course. If you want to use a raw IP address there instead of a hostname, I believe that's also possible. This happens to be a "one-line solution" in qmail. I don't know how to do it in other MTAs off the top of my head, but I'm guessing each one will be different. Probably radically different. It wouldn't surprise me if it requires more than one line of configuration in most cases.