By rmmohan
I recently created a droplet for ubuntu 16.04. Following one of the tutorials I set up ssh login and disabled login with username password. I also set up a firewall.
I am able to login to my droplet using my ssh keys. I then purchased a domain and pointed it to the digitalocean nameservers. I have checked the details and the domain is pointing to the correct location.
I initiated a process to print a string in my droplet. If I open another console within the droplet and fire the command ‘curl localhost:8124’, it returns me the correct output. However if I try accessing the process using the ip address like ‘curl <ip address>:8124’, I get an error message. This command does not work even if I fire it within the digital ocean console.
I have modified my firewall settings to accept TCP connections for port 8124. I am not able to figure out what is the error.
Kindly let me know if my question seems to be ambiguous and needs more clarity.
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi,
You may need to allow the Port 8124 for the IP address you have for the droplet.
like iptables -I INPUT -s <IP_ADDRESS> -p tcp -j ACCEPT
or iptables -I INPUT -s <IP_ADDRESS> -p tcp -j ACCEPT
Did you install curl library? To install curl use the following commands with php 5.0 : apt-get install php5-curl with php7 : apt-get install php7.0-curl
Hi!
I initiated a process to print a string in my droplet.
What interface is that process listening on? The default for some program may be localhost or 127.0.0.1 which causes them to be inaccessible from outside of the Droplet. Try configuring the process to listen on 0.0.0.0 (all interfaces). Assuming your firewall is set up correctly, it should work.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.