【发布时间】:2020-04-24 05:40:55
【问题描述】:
我的 Windows 10 PC 上安装了 python 3.8.1。
我在要设置为服务器的目录中从 PowerShell 运行以下命令
python -m http.server 8000
运行命令后得到如下响应
在 :: 端口 8000 (http://[::]:8000/) 上提供 HTTP ...
我能够访问目录 localhost:8000 但不能访问 0.0.0.0:8000 或 http://127.0.0.1:8000/
我无法从同一台 PC 或同一网络上的另一台 PC 访问我的外部 IP 上的服务器。
我检查了防火墙以确保 Python 是一个被接受的应用程序并且我的网络设置为私有。
【问题讨论】:
标签: python-3.x windows powershell localhost simplehttpserver