How to open my localhost for WWW? (Port Forwarding?)

I am running Apache / php on my localhost and would like to make this public from the Internet.

I think this is achieved by port forwarding? Can someone point me in the right direction?

+7
source share
7 answers

It depends on your connection.

If your computer has a public IP address, it is already on the Internet. Then you only need to allow connections to port 80, both on the local firewall and on the home / corporate firewall.

If your computer is located behind a set-top box or inside a corporate network, most likely you are not on the Internet. In some cases, the router performs NAT ( Network Address Translation ) between the local (non-routable) network and the Internet. In this particular case, you need to configure port forwarding on the set-top box or router.

+6
source

Ok sir, you should try ngrok , it's free and works with everything that I throw at it (node ​​servers, xampp, etc.)

+7
source

You might want to check out Pagekite , an open source software that allows you to expose your local resources on the outside Internet without having to reconfigure your router or firewall.

There's a Show service there that does the same, although it seems a bit more limited.

+4
source

You can try beame-insta-ssl, this is a good way to get free tunneling services and a free SSL certificate to expose your localhost. This is open source on git here: https://github.com/beameio/beame-insta-ssl/

+1
source

Only port forwarding will work, but you will need to connect to your server through an IP address.

take a look at dyndns.com, there you can get a DNS identifier pointing to your server.

After that, you set the port 80 of the router (HTTP) or 443 (HTTPS) to point to the port of the HTTP server of your PC (this can be any port you want)

0
source

Does it depend on what you mean localhost? Each system has its own localhost.

If you mean that you have something like: "your system" ↔ "gateway / wifi router" ↔ Internet, then you should configure port mapping from the external interface of the router to the IP address of your server. For more information refer to the documentation for the gateway / router.

0
source

Another tool for port forwarding through an OpenVPN or SSH tunnel is https://portmap.io . If you use multiple vhosts on local Apache, you can set the host header with the desired host name.

0
source

Source: https://habr.com/ru/post/1335888/


All Articles