0

I have a Windows server 2019 that have many VMs instances (running using HyperV). Each VMs has its own private IP and has some apps running inside and expose via ports.

It looks like:

  • VM1: running app nodejs port 3000, private ip: 10.10.10.1

  • VM2: running app php port 3001, private ip: 10.10.10.2

Now I want to setup a secure connection so my colleagues can access the apps inside each vm without expose them to internet, how can I achieve it?

If I have a Ubuntu Server and SSH I will use dynamic port forwarding like this article

https://www.digitalocean.com/community/tutorials/how-to-route-web-traffic-securely-without-a-vpn-using-a-socks-tunnel

Does Windows have something alternative?

I have did a lot of tutorials but it seem it does not work for me.

1 Answer 1

1

I don't know Windows, but for this purposes you should configure a NAT between the host and the guests. Hyper-V has this functionality.

Each guest (virtualmachine) will responde internally in port 22, and the hosts will redirect trafic, for exemple, from ports 2222, 2223, 2224 to 22 in each vm.

Then your colleagues could start and SSH tunnel from their machines:

ssh -L localhost:3001:10.10.10.1:3001 -p 2222 user@<windowserverip>

And after that, they can access the application on por 3001 in their own machines.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .