Running a ruby on rails project on my mac. I need to test it on my android phone. Is there a way to view my mac localhost on my android phone?
Although one answer has been accepted but this worked for me:
ifconfig
inside terminal and look for en0/en1 -> inet
it should be something like 19*.16*.1.4
.)Open your mobile settings and go to network-> long press your wifi network-> modify network -> scroll down to advanced options -> chose proxy manual and in proxy hostname type your address i.e. 19*.16*.1.4
inside port enter your port. and save it.
search for what is my ip
in google chrome, and get your ip, lets say it is 1**.1**.15*.2**
1**.1**.15*.2**:port/
from your mobile device.It is as simple as this.