地址:http://mirrors.163.com/.help/centos.html html
首先備份/etc/yum.repos.d/CentOS-Base.repo docker
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup
下載對應版本repo文件, 放入/etc/yum.repos.d/(操做前請作好相應備份) centos
運行yum makecache生成緩存 緩存
eple源: ui
rpm -Uvh http://ftp.sjtu.edu.cn/fedora/epel/6/i386/epel-release-6-8.noarch.rpm this
docker 安裝: spa
You will need RHEL 6.5 or higher, with a RHEL 6 kernel version 2.6.32-431 or higher as this has specific kernel fixes to allow Docker to work. code
CentOS 6.5已是2.6.32-431內核了,因此最好安裝這個版本。 htm
yum -y install docker-io升級:
yum -y update docker-io
手動升級: ci
wget https://get.docker.io/builds/Linux/x86_64/docker-latest -O docker mv -f docker /usr/bin/docker
升級完成
啓動:
service docker start
開機啓動:
chkconfig docker on