docker安装
1.yum -y install gcc
2.yum -y install gcc-c++
3.yum -y install yum-utils
##阿里云镜像
4.yum-config-manager --add-repo http://mirrors.aliyun.com/docker-ce/linux/centos/docker-ce.repo
5.yum makecache fast
##安装docker引擎
6. yum install docker-ce docker-ce-cli containerd.io
##启动
7.systemctl start docker
##开机自启动
8.systemctl enable docker
##测试
9.docker run hello-world
##阿里云镜像加速器,注册阿里云在容器镜像服务中,镜像工具-->镜像加速器选择对应的版本

1.mkdir -p /etc/docker
2.tee /etc/docker/daemon.json <<-'EOF'
{
"registry-mirrors": ["https://****.mirror.aliyuncs.com"]
}
EOF
3.systemctl daemon-reload
4.systemctl restart docker

浙公网安备 33010602011771号