Reputation: 678
I have a rails server running on my machine. I am running the server using the following command:
rails s -b my_computer_ip
Now, I am trying to access the server on my phone's browser using the following command
http://my_computer_ip:3000
but I keep getting: "The site cannot be reached"
Both my phone and computer are connected over the same network.
I have tried following options:
rails s -b 0.0.0.0 (On computer)
http://192.168.1.80:3000 (On phone)
But do not work.
Earlier I used to connect to server on my phone in the same way I have mentioned but I don't understand what issue is now cropping up.
PS: When I do the following:
http://my_computer_ip
on my phone's browser, I get the page saying Apache server is running.
Upvotes: 0
Views: 251
Reputation: 454
This is a networking concept error. You have to enable the port 3000
in your router. Instead, try running the server on port 80
, your firewall is probably blocking port 3000
.
Upvotes: 1