Hi Marc, * Marc Haber <mh+debian-devel@zugschlus.de> [2025-10-24 18:13]:
Yes, the logic works out exactly the same way. And if you have no strong feelings about 127.0.0.1 being associated with something else besides "localhost", you might even get away with that.On Mon, Oct 13, 2025 at 11:56:21PM +0200, Timo Röhling wrote:The usual "trick" to get your own domain name is via hostname canonicalization, i.e, you run gethostbyname("apollo"), which returns 127.0.1.1, and afterwards gethostbyaddr(127.0.1.1), which returns "apollo.example.com". The 127.0.1.1 entry in /etc/hosts makes this work and still lets the software on your computer behave exactly as if your computer had a static IP with a proper DNS entry, regardless of your actual network setup.That would work with 127.0.0.2 as well, right?
Cheers Timo -- ⢀⣴⠾⠻⢶⣦⠀ ╭────────────────────────────────────────────────────╮ ⣾⠁⢠⠒⠀⣿⡁ │ Timo Röhling │ ⢿⡄⠘⠷⠚⠋⠀ │ 9B03 EBB9 8300 DF97 C2B1 23BF CC8C 6BDD 1403 F4CA │ ⠈⠳⣄⠀⠀⠀⠀ ╰────────────────────────────────────────────────────╯
Attachment:
signature.asc
Description: PGP signature