Simple Forward Port / IP from VM Box to Localhost (ex Windows 10)

Simple Forward Port / IP from VM Box to Localhost (ex Windows 10)

If we have web Front End / API / docker container , etc - in VM Box . So, how we can publish in our localhost . Example windows and then publish it on internet ?

In this case , 1 used vagrant - Linux Ubuntu 18.04. So, simple way is - add in vagrantfile , before vagrant up.

No alt text provided for this image

Then , Vagrant Up for check , and we can see like this . Port 80 and 9090 , publish to localhost from VM Box

No alt text provided for this image

Next , we can add - static IP in VM Box , to communicate with localhost. In LAN (Local Area Network). Like this .... :)

No alt text provided for this image
No alt text provided for this image

So we can , create web / api / docker container / etc , then publish on localhost and from localhost , if neeeded, it can publish too , in Internet :)


Thank You,

要查看或添加评论,请登录

Edwin Baktian的更多文章

社区洞察

其他会员也浏览了