Art*_*gan 2 port containers docker
当我想检查我的端口时,它只允许我的第 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.
Run Code Online (Sandbox Code Playgroud)
正确的调用curl需要在 URL 中包含协议标识符,并且端口需要附加到主机名上,并使用冒号且不带空格。例如,要访问本地主机上通过端口 8080 提供服务的 HTTP 服务器,您需要使用:
curl http://localhost:8080
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
7281 次 |
| 最近记录: |