Question

Connect to webserver by droplet IP

Posted October 3, 2015 3.1k views
Ubuntu Node.js DigitalOcean

Could I connect to droplet webserver through droplet IP?

I have created a very simple nodejs web server. When I try to connect to this server through localhost (127.0.0.1), I have get right answer. it’s OK.
But when I try connect to the server through droplet IP, I have get a timeout error. Ping to droplet IP works fine from my windows workstation.

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

2 answers

Normally you would use nginx or another web server as a reverse proxy. However if you’re set on accessing the app directly, have it listen on 0.0.0.0 instead of 127.0.0.1.

Check out if there is any firewall rules preventing web access. Also use netstat to see what addresses:ports are available and listening to connections:

netstat -plnt
Submit an Answer