docker install - TuPengXiong/TuPengXiong.github.io GitHub Wiki
#ubuntu 14.04 docker的安装
-
docker文件的下载 http://www.docker.com/products/docker#/linux
进入下载页面选择ubuntu14.04
-
docker ubuntu kernel 最小为 3.10
查看kernel版本
uname -r
4.4.0-38-generic
- 更新APT源
sudo apt-get update
sudo apt-get install apt-transport-https ca-certificates
- 添加一个新的GPG
sudo apt-key adv
--keyserver hkp://p80.pool.sks-keyservers.net:80
--recv-keys 58118E89F3A912897C070ADBF76221572C52609D
- 添加dpcker apt的搜索包信息 /etc/apt/sources.list.d/docker.list
Ubuntu version | Repository |
---|---|
Precise 12.04 (LTS) | deb https://apt.dockerproject.org/repo ubuntu-precise main |
Trusty 14.04 (LTS) | deb https://apt.dockerproject.org/repo ubuntu-trusty main |
Xenial 16.04 (LTS) | deb https://apt.dockerproject.org/repo ubuntu-xenial main |
sudo apt-get update
- 验证APT
apt-cache policy docker-engine
docker-engine:
已安装: (无)
候选软件包:1.12.2-0~trusty
版本列表:
1.12.2-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.12.1-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.12.0-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.11.2-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.11.1-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.11.0-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.10.3-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.10.2-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.10.1-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.10.0-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.9.1-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.9.0-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.8.3-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.8.2-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.8.1-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.8.0-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.7.1-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.7.0-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.6.2-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.6.1-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.6.0-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
1.5.0-0~trusty 0
500 https://apt.dockerproject.org/repo/ ubuntu-trusty/main amd64 Packages
-
运行 sudo apt-get upgrade
-
安装 linux-image-extra-*内核软件包
sudo apt-get update
sudo apt-get install linux-image-extra-$(uname -r) linux-image-extra-virtual
- 安装 docker
sudo apt-get install docker-engine
- 启动docker守护进程。
sudo service docker start
- 验证docker是否正确安装。
sudo docker run hello-world