0

I wanted to ask if it would be possible to access all ports of a virtual machine using a subdomain.

As a small example:

host: 10.0.2.1

VM1: 10.0.2.2

VM2: 10.0.2.3

As result:

vm1.example.com:any -> 10.0.2.2:any

vm2.example.com:any -> 10.0.2.3:any

I was thinking of a reverse proxy, but if I understood it correctly, there would have to be an entry for each port.

Is there an easier way to address Proxmox virtual machines with only one domain?

Tero Kilkanen
  • 34,499
  • 3
  • 38
  • 58

1 Answers1

0

Implement IPv6. Use globally routable /64s on every subnet.

For both IPv4 and IPv6, send traffic via public addresses through reverse proxies and other load balancing methods. Several reverse proxies are capable of opening a port range. Implement a firewall and open the necessary ports.

For IPv4, use NAT (NAPT) where you must due to address shortages. From the outside, you can't tell hosts behind a NAT apart just by name or IP. Either implement IPv6, connect to a jump box or reverse proxy, or use different ports and map those in your NAT. Note that NAT port mapping will not work if you need all ports to go to multiple hosts.

John Mahowald
  • 30,009
  • 1
  • 17
  • 32