0

An nginx server is up and running locally on my system[ubuntu 14.04]. But i am having difficulty accessing the same server from my public ip address, or from any other system using my public ip address. I have just started looking into nginx, its been great, but am stuck at this point now.

Issue : Nothing displays when i use my public ip address in the browser.

below is the config file "firstsite.com"

server {
        listen   80 default_server;
        server_name firstsite.com;

        root /var/www/uwsgiSite;
        index index.html;

        location / {
                try_files $uri $uri.html $uri/ index.html;
                allow all;
        }
}

which is available in "sites-available" and soft linked into "sites-enabled" folders. Also i have an entry in the /etc/hosts file

127.0.0.1   firstsite.com

All the folders/files are available in /var/www with permission.

Later i would like to connect the same with a domain name [buy purchasing one] to my computer. For now, i am looking to make it work just with my public ip address, which is not working yet. Please guide me as to what is missing to make it accessible.

1 Answer 1

0

127.0.0.1 is a local-only loopback address, and is local ONLY to this system you have it setup on, it is not even accessible to the network to a laptop on the same network right next to it. Please search Google for "127.0.0.0/8 loopback special use" to understand why.

You must log in to answer this question.

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