1、首先更新资源update。sudo apt-get update
2、安装docker。sudo apt-get install docker
3、安装docker.io。sudo apt-get install docker.io
4、安装docker-registry。sudo apt-get install docker-registry
5、开始启动我们的dockersudo systemctl start docker
6、把ubuntu14.04的镜像pull到本地(这里使用的ubuntu14.04,当然你也可以使用centos等其他版本)。sudo docker pull ubuntu:14.04
7、完成后可以通过ubutnu14.04镜像创建一个容器。sudo docker create ubuntu:14.04
8、开始运行容器,然就就可以尽情的在docker容器中使用shell了。sudo docker run -i -t ubuntu:14.04 /bin/bash