https://www.cnblogs.com/sanduzxcvbnm/p/13367071.html
一. 让两个不在同一网段的容器网络互通
# 自定义一个网络 docker network create --driver bridge --subnet 192.168.0.0/16 --gateway 192.168.0.1 mynet #把两个单独的容器加入到此网络 docker network connect mynet nginx-test_nginx_1 docker network connect mynet m3-test-centos #测试连通性 docker exec -it m3-test-centos ping nginx-test_nginx_1 #查看docker网络 docker network ls docker network inspect mynet