manage.py runserver [英] manage.py runserver
问题描述
我正在运行
python manage.py runserver
从机器A
当我试图检入机器B
我键入的URL是 http:// A:8000 /
我收到一个错误,如
系统返回:(111)连接拒绝
I am running python manage.py runserver from a machine A when I am trying to check in machine B The url I typed is http://A:8000/ I am getting an error like The system returned: (111) Connection refused
推荐答案
您可以通过
./ manage.py runserver 0.0.0.0:8000
./manage.py runserver 0.0.0.0:8000
而且您可以从任何机器到达您的服务器你的网络
只需在浏览器中的其他机器上输入 http://192.168.0.1:8000
其中 192.168.0.1
是你的服务器的IP ...并且它准备好了....
And than you will be able to reach you server from any machine in your network.
Just type on other machine in browser http://192.168.0.1:8000
where 192.168.0.1
is IP of you server... and it ready to go....
或在你的情况下:
- 在机器上
A
在命令行./ manage.py runserver 0.0.0.0:8000$c$ c>
- 比浏览器类型
http:// A:8000 $中尝试机器
B
c $ c> - 喝一口啤酒。
- On machine
A
in command line./manage.py runserver 0.0.0.0:8000
- Than try in machine
B
in browser typehttp://A:8000
- Make a sip of beer.
这篇关于manage.py runserver的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!