网络模式

docker的四种网络模式分别是?
运维

docker的四种网络模式分别是?

62 0

四种网络模式:(推荐教程:docker教程)host模式container模式none模式bridge模式1docker run -it --rm --net=host centos_with_net bash使用--net=container:container_id/container_name,多个容器使用共同的网络看到的ip是一样。使用--net=none指定,这种模式下不会配置任何网络。使用--net=bridge指定,不用指定默认就是这种网络模式。这种模式会为每个容器分配一个独立的Networ