解决centos7docker内无法访问宿主机的问题

1 按顺序执行下面命令
2 nmcli connection modify docker0 connection.zone trusted
3 systemctl stop NetworkManager.service
4 firewall-cmd --permanent --zone=trusted --change-interface=docker0
5 systemctl start NetworkManager.service
6 nmcli connection modify docker0 connection.zone trusted
7 systemctl restart docker.service

你可能感兴趣的:(docker)