docker有不变的好处
容器轻量级
vi /etc/sysctl.conf
[root@localhost ~]# sysctl -p
net.ipv4.ip_forward = 1
net.bridge.bridge-nf-call-iptables = 1
net.bridge.bridge-nf-call-ip6tables = 1
镜像下载地址
https://hub.docker.com/
命令
docker search 镜像
docker pull 镜像
docker pull quay.io/coreos/flannel:v0.12.0-amd64
镜像地址 镜像名字 镜像版本、
加速器
dao云
https://www.daocloud.io/mirror
阿里云
https://cr.console.aliyun.com/cn-hangzhou/instances/mirrors
centos要用7版本
改名
docker tag centos:7 centos:latest
-i 交互
-t tti
进入容器下命令
yum provides ip
yum install iproute -y
docker attach test