CentOS7.2安装Docker

安装Docker及配置Docker国内加速

卸载旧版本安装包

yum remove docker docker-common docker-selinux docker-engine -y

安装依赖包

yum install -y yum-utils device-mapper-persistent-data lvm2

添加yum 源仓库

yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo

清除yum缓存,重新加载yum源

yum clean all
yum makecache

下载安装docker-ce

yum install docker-ce

注册自己daocloud账号

http://www.daocloud.io/

然后配置Docker加速器*

https://www.daocloud.io/mirror

curl -sSL https://get.daocloud.io/daotools/set_mirror.sh | sh -s http://xxxxxdb2.m.daocloud.io

重启一下docker

systemctl restart docker


参考

0%