Expose Apache/Nginx web server
This tutorial will explain how to expose a localhost Apache/Nginx web server and give it a shareable link that is accessible from the internet.
Last updated
Was this helpful?
This tutorial will explain how to expose a localhost Apache/Nginx web server and give it a shareable link that is accessible from the internet.
Last updated
Was this helpful?
There are multiple ways to reach our locahost web server depends on your requirements.
We will run Apache or Nginx web server through docker:
This will run Apache/Nginx web server in localhost:3000
Run HTTP tunnel and point it to Apache/Nginx web server
After creating the tunnel and getting a shareable link to our website, we can access the website through https://apache.loclx.io
or http://apache.loclx.io
.
We will run Apache/Nginx web server through docker as we did with HTTP tunnel above:
This will run Apache/Nginx web server in localhost:3000
You either can:
Let LocalXpose client to terminate the TLS traffic by providing the TLS certificate , so in this case you don't need to configure your Apache/Nginx web server TLS settings for example:
Now the TLS tunnel will be accessible from the internet through https://your-domain.com
.
Since HTTP works on top of TCP, then a TCP tunnel will also works.
This will create a TCP tunnel us.loclx.io:8888, you can access your Apache/Nginx webserver from the internet through http://us.loclx.io:8888
Or configure your Apache or Nginx web server to deal with TLS termination by using mod_ssl
module for Apache and for Nginx you can follow this tutorial , then you don't need to pass the TLS certificate to LocalXpose client for example:
Since you are using TLS tunnel to access your localhost webserver, you will not be able to use .
Since you are using TCP tunnel to access your localhost webserver, you will not be able to use .