linuxminit18.02安装docker-ce以及docker-machine

官网没给教程,因为mint和ubuntu比起来差了点,我就自己记录下
先上官网教程
教程页:https://docs.docker.com/install/linux/docker-ce/ubuntu/
上个ubuntu的代号以及版本

代号 版本
precise 12.04
trusty 14.04
vivid 15.04
wily 15.10
xenial 16.04
yakkety 16.10
zesty 17.04

上一些mint的代号以及版本

代号 版本
17.0 Qiana
17.1 Rebecca
17.2 Rafaela
17.3 Rosa
18.0 Sarah
18.1 Serena
18.2 Sonya
18.3 Sylvia

然后老规矩抄一遍官方的教程
卸载老版本
sudo apt-get remove docker docker-engine docker.io
安装依赖库
sudo apt-get install \
apt-transport-https \
ca-certificates \
curl \
software-properties-common
添加GPG密钥
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
然后加repo,这是官方的
sudo add-apt-repository \
“deb [arch=amd64] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) \
stable”
修改后
sudo add-apt-repository \
“deb [arch=amd64] https://download.docker.com/linux/ubuntu \
zesty \
stable”
先说下为什么修改为zesty版本,zesty版本是ubuntu的17.04的,现在是18年3月份,所以算是除了10月份的版本就是最新的了,因为我的mint是18.02的版本,所以就选择了这个版本,如果mint是17.03的可以考虑用xenial,也就是ubuntu16年的版本
更新索引
sudo apt-get update
安装
sudo apt-get install docker-ce
hello-world来一波
sudo docker run hello-world

安装docker-machine
官网教程
教程页:https://docs.docker.com/machine/install-machine/
依旧抄一遍官方的教程
If you are running on macOS:

$ curl -L https://github.com/docker/machine/releases/download/v0.14.0/docker-machine-`uname -s`-`uname -m` >/usr/local/bin/docker-machine && \
  chmod +x /usr/local/bin/docker-machine

If you are running on Linux:

$ curl -L https://github.com/docker/machine/releases/download/v0.14.0/docker-machine-`uname -s`-`uname -m` >/tmp/docker-machine && \
sudo install /tmp/docker-machine /usr/local/bin/docker-machine

If you are running with Windows with Git BASH:

$ if [[ ! -d "$HOME/bin" ]]; then mkdir -p "$HOME/bin"; fi && \
curl -L https://github.com/docker/machine/releases/download/v0.14.0/docker-machine-Windows-x86_64.exe > "$HOME/bin/docker-machine.exe" && \
chmod +x "$HOME/bin/docker-machine.exe"

猜你喜欢

转载自blog.csdn.net/bwlab/article/details/79513996