docker映射问题

问题描述

创建了一个docker容器,无法访问它的服务

信息:

尝试解决

重新创建一个容器,尝试运行,同样的错误 http://172.22.0.2:5005

image-20240919110114653
1
2
3
4
5
6
7
The connection was reset

The connection to the server was reset while the page was loading.页面加载时,连接已重置

The site could be temporarily unavailable or too busy. Try again in a few moments.网站暂时不用或太忙
If you are unable to load any pages, check your computer’s network connection.可能是计算机网络问题
If your computer or network is protected by a firewall or proxy, make sure that Firefox is permitted to access the web.防火墙或代理保护

ping 172.22.0.2

可以ping通

nmap -p 5005,8443 172.22.0.2

端口开通

1
2
3
4
5
6
7
8
9
10
Starting Nmap 7.94SVN ( https://nmap.org ) at 2024-09-19 11:17 CST
Nmap scan report for 172.22.0.2
Host is up (0.000043s latency).

PORT STATE SERVICE
5005/tcp open avt-profile-2
8443/tcp open https-alt
MAC Address: 02:42:AC:16:00:02 (Unknown)

Nmap done: 1 IP address (1 host up) scanned in 0.24 seconds

修改url https://localhost:8443/accounting

可以访问了