Notes icon indicating copy to clipboard operation
Notes copied to clipboard

docker容器和宿主机通信

Open any86 opened this issue 4 years ago • 0 comments

查看宿主机ip, 使用ifconfig:

image

查看容器的网络配置, 使用docker inspect 容器id:

image

进入容器测试:

docker exec -it 容器id /bin/bash

any86 avatar Jan 20 '21 01:01 any86