docker_practice/install/centos.md

23 lines
578 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

## CentOS 系列安装 Docker
Docker 支持 CentOS6 及以后的版本。
### CentOS6
对于 CentOS6可以使用 [EPEL](https://fedoraproject.org/wiki/EPEL) 库安装 Docker命令如下
```
$ sudo yum install http://mirrors.yun-idc.com/epel/6/i386/epel-release-6-8.noarch.rpm
$ sudo yum install docker-io
```
### CentOS7
CentOS7 系统 `CentOS-Extras` 库中已带 Docker可以直接安装
```
$ sudo yum install docker
```
安装之后启动 Docker 服务,并让它随系统启动自动加载。
```
$ sudo service docker start
$ sudo chkconfig docker on
```