使用阿里云镜像加速安装docker

  

系统要求

Ubuntu 14.04、16.04

Debian 7.7、8.0

CentOS 7.X

Fedora 20、21、22

OracleLinux 6、7

安装方法:

curl -sSL http://acs-public-mirror.oss-cn-hangzhou.aliyuncs.com/docker-engine/internet | sh -

            

如果你使用的是阿里云主机,可以通过内网地址运行这个脚本

curl -sSL http://acs-public-mirror.oss-cn-hangzhou.aliyuncs.com/docker-engine/intranet | sh -

            

安装测试版、实验版的Docker Engine

    ## 测试版

    curl -sSL http://acs-public-mirror.oss-cn-hangzhou.aliyuncs.com/docker-engine/test/internet | sh

    curl -sSL http://acs-public-mirror.oss-cn-hangzhou.aliyuncs.com/docker-engine/test/intranet | sh

 

    ## 实验版

    curl -sSL http://acs-public-mirror.oss-cn-hangzhou.aliyuncs.com/docker-engine/experimental/internet | sh

    curl -sSL http://acs-public-mirror.oss-cn-hangzhou.aliyuncs.com/docker-engine/experimental/intranet | sh

            

注意

1. 因为测试版、实验版的版本号格式不统一,所以通过制定版本的方式安装可能存在问题。

Ubuntu的测试版、实验版的版本号格式示例: 1.12.0~rc1、1.12.0~rc2
CentOS的测试版、实验版的版本号格式示例: 1.11.0、1.12.0

2. CentOS系统上会为正式版、测试版、实验版分别添加数据源描述文件。如果你从正式版想要切换到测试版、实验版的话,请删除数据源描述文件。

描述文件分别为 /etc/yum.repos.d/docker-main.repo、/etc/yum.repos.d/docker-test.repo、/etc/yum.repos.d/docker-experimental.repo

FAQ

1. 帮助文件地址

http://acs-public-mirror.oss-cn-hangzhou.aliyuncs.com/docker-engine/help

2. yum update、apt-get update时,报出 404 Not Found 的错误,源站路径更新导致镜像源的路径不正确,解决办法:

    curl -sSL http://acs-public-mirror.oss-cn-hangzhou.aliyuncs.com/docker-engine/resume | sh -

            

相关链接

<!--[if !supportLists]-->§ <!--[endif]-->官方主页: http://docs.docker.com/

猜你喜欢

转载自jaychang.iteye.com/blog/2358817