执行一下代码,全部复制,一起粘贴即可
yum -y install gcc yum -y install gcc-c++ yum install -y yum-utils device-mapper-persistent-data lvm2 yum-config-manager --add-repo http://mirrors.aliyun.com/docker-ce/linux/centos/docker-ce.repo yum makecache fast
yum -y install docker-ce
systemctl start docker
vim /etc/docker/daemon.json
安装vim插件
yum -y install vim
编辑docker文件,添加阿里云镜像
vim /etc/docker/daemon.json
systemctl daemon-reload