This has been bothering me for quite some time, I feel this may be possible, but given my decent knowledge of networking, I can't seem to figure how.
It's easiest to understand with an example: if I run 2 servers named serverA and serverB, and I wanted to be able to ssh into each of them, I could do ssh serverA.home.example.com or serverB.home.example.com and have my internal DNS resolve these requests, both from within the LAN (which is already does) BUT also over the WAN.
Realize this is an example, I know this could be accomplished with port forwarding and changing the ssh port on each - I'm just interested in learning and understanding DNS better.
My line of thought is if a DNS request comes into port 53, my DNS server responds with my public IP address (assuming that host is in its table). What I can't figure out is when the request is then made to my public address, NAT would have no idea which host the request is intended for.