Hello,
I'm trying to access my Django server from another computer on the same network. I've set up my server and can view everything correctly usingpython manage.py runserver
and going to http://127.0.0.1:8000
but when I try to use python manage.py runserver 0.0.0.0:80
, I can't view my Django page from another computer. The computer hosting the Django server has intranet IP 192.168.1.146. On my secondary computer, I fire up a browser and try to access http://192.168.1.146:80
to no avail. I've also forwarded port 80 (and I've tried 8000 as well) also to no avail :(. HELP!
views:
71answers:
4
A:
Sounds like it is a firewall issue then. Did you make sure to open port 80 on your server computer?
webdestroya
2010-05-25 04:29:51
A:
From your mention of forwarding port 80, it sounds like your second computer is on a different network (router) from the one running Django. In that case, you should browse to the IP of the Django network's router - the 192.168 address is only visible from behind that router, and port forwarding will ensure that your request goes to the right machine.
Daniel Roseman
2010-05-25 07:18:36
A:
what OS are you running this on? have you tried to give the command root privileges? (assuming you're running it on ubuntu/linux)
try running this instead:
sudo python manage.py runserver 0.0.0.0:80
gtujan
2010-05-25 08:53:16
A:
As far as I understand, 0.0.0.0 is a non-routable IP.
It will only work on the local machine, if you bind a socket to the address.
Gary D
2010-07-29 22:48:44