码迷,mamicode.com
首页 > 其他好文 > 详细

CentOS6.4安装Docker

时间:2014-12-17 12:53:52      阅读:194      评论:0      收藏:0      [点我收藏+]

标签:docker

首先,需要安装EPEL仓库

# wget http://mirrors.yun-idc.com/epel/6/i386/epel-release-6-8.noarch.rpm
# rpm -ivh epel-release-6-8.noarch.rpm

安装docker-io

# yum -y install docker-io

启动docker服务

# /etc/init.d/docker start
Starting cgconfig service:                                 [  OK  ]
Starting docker:                                           [  OK  ]

设置docker服务开机启动

# chkconfig docker on

测试是否正常工作

# docker run -i -t fedora /bin/bash
Unable to find image 'fedora' locally
fedora:latest: The image you are pulling has been verified

bfe0bb6667e4: Downloading  6.48 MB/259.4 MB 51m9s
511136ea3c5a: Already exists 
00a0c78eeb6d: Already exists 

下载中,由于网速原因,等待比较长一段时间后

# docker run -i -t fedora /bin/bash
Unable to find image 'fedora' locally
fedora:latest: The image you are pulling has been verified

bfe0bb6667e4: Pull complete 
511136ea3c5a: Already exists 
00a0c78eeb6d: Already exists 
Status: Downloaded newer image for fedora:latest
bash-4.3#

可以看出我们已经运行在docker容器中了

可以像Fedora一样操作了

 

CentOS6.4安装Docker

标签:docker

原文地址:http://blog.csdn.net/u011650565/article/details/41979151

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!