【发布时间】:2020-05-29 10:21:55
【问题描述】:
当我想检查我的端口时,它只允许我的第 80 个端口。我也试过http://。是一样的。我无法检查特定端口。检查屏幕截图。我的操作系统是 Windows 10 Pro,这是 Powershell。我也在 CMD 上检查过。我正在共享包含我的代码的代码和图像。
:
curl localhost /* ( It shows the information as in image, there is no problem with default port 80) */
curl localhost: 8080 //(httpd's port as i assigned)
curl: The URI prefix is not recognized.
curl localhost: 3306 // (mysql's port as i assigned)
curl: The URI prefix is not recognized.
【问题讨论】:
-
请不要将文字作为图片发布。另外,你没有给 curl 一个 URL 类型前缀(比如
http://),告诉它使用哪个协议。 -
阿米泰你好,代码很多,所以我只添加了部分代码。我试过 http:// 它也不起作用。
-
编辑您的问题以反映您的尝试。您无法获得与您未提出的问题相关的答案。此外,主机名和端口号之间的空格应删除:
curl http://localhost:8080 -
这就是我喜欢这个网站的原因!非常感谢阿米泰!它以这种方式工作。最好的问候。
标签: docker containers port