This question has already been answered:

Began to study the network and all that. I decided to deploy a server for home use from an old PC - everything turned out.

But the question is: is it possible to access my data ( /var/www/html/* ) from the Internet by writing the IP address of my machine in the address bar of the browser? Just ask if you can paint.

Reported as a duplicate by members of aleksandr barakin , Mike , tutankhamun , Bald , cheops 13 Sep '16 at 4:35 .

A similar question was asked earlier and an answer has already been received. If the answers provided are not exhaustive, please ask a new question .

  • 2
    If you have a real IP and the port is not closed with a firewall, then you can - Mike

1 answer 1

You must have a static (dedicated) IP from a provider that belongs only to you. If dynamic and is used not only by you, but also by other users of the network, then nothing will work right away.

Further, if you are connected through a router, and the router distributes the Internet, you need to forward the port to your static IP and connect it to the local machine via NAT and configure access rights on the local machine itself.

If you connect to the network directly on your computer (you are connecting to the Internet), then you just need to allow access through the firewall.

Next, you need your Apache to be configured on the external interface of the network card, and not on the internal one and everything will work.

If you want to expand the site, then do not do it on a local machine, buy hosting and get more benefits from its use.

  • one
    At the expense of dynamic ip you are not quite right. theoretically you can work this way. but it is certainly not very stable. need to use external dyndns systems and call by name - Mike
  • @Mike Yes, it is so :) But the user's question was to enter exactly my IP into the browser string, and not the external addresses, and I answered that it wouldn’t work out exactly about this possibility :) - Firepro
  • @Mike, how will DynDNS help with a gray (invisible from the Internet) user address? - ߊߚߤߘ
  • one
    @Arhad I was talking about real (white) dynamic IP - Mike