切記是root權限下操做一下全部操做 查看你當前的內核版本
yum update
yum remove docker docker-common docker-selinux docker-engine
yum install -y yum-utils device-mapper-persistent-data lvm2
yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
yum list docker-ce --showduplicates | sort -r
sudo yum install docker-ce
yum install docker-ce-17.12.0.ce
systemctl start docker
systemctl enable docker
docker version