I
I
iPsixopad2019-04-22 00:15:17
Domain Name System
iPsixopad, 2019-04-22 00:15:17

How to give external access to multiple local servers using DNS?

Good day!
I will try to describe the question as accurately and concisely as possible!
Initial data:
- domain example.com with external ip bound - 80.185.68.156
- external ip of router - 80.185.68.156, local - 192.168.1.1
- wi-fi router with address 192.168.1.2
- ip of servers in LAN: 192.168.1.10, 192.168.1.11 and 192.168.1.12
The situation itself: a home router with a static ip is tied to a domain (hosting). That is, pinging example.com shows the external ip address of the router. At home, the Asus router distributes the LAN. And at home, there are 3 Ubuntu servers in LAN. VestaCP is configured on one of the servers, and a site with the address example.com is created. This site is externally accessible at example.com, which is fine.
To make this site accessible from the outside, I set up a DMZ host on the router. That is, the local address of the server with the website is 192.168.1.10 as the DMZ host. It turns out that by typing example.com in the browser we get to the address 80.185.68.156, and then to the address 192.168.1.10. Of course, for us it all looks like a regular site with the address example.com.
The question is this: if I want to make a couple more servers available via http from the outside with local addresses 192.168.1.11 and 192.168.1.12 and external addresses like sub1.example.com and sub2.example.com, then in which direction should I look?
Setting up DNS, setting up forwarding on the router, or what else?
For some reason, it seems to me that you need to set up a domain on the router (there is such an option) and already register subdomains and redirection rules to local ip there, but this is not accurate :)
Thanks in advance for your help!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
R
Rsa97, 2019-04-22
@Rsa97

Look towards Reverse Proxy on the DMZ host.

D
d-stream, 2019-04-22
@d-stream

1. it makes no sense to turn back the DMZ - it's enough to forward port 80/443 on your router to your server for
nat "classic" hosts)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question