尝试从ubuntu上的官方documentation安装docker并收到此错误
$ sudo apt-get install docker-ce=18.06.1~ce~3-0~ubuntu docker-ce-cli=18.06.1~ce~3-0~ubuntu containerd.io
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Version '18.06.1~ce~3-0~ubuntu' for 'docker-ce-cli' was not found
最好的部分是我们昨天刚刚在另一台机器上安装了docker,然后就可以了。有什么作用?
答案 0 :(得分:5)
据我所知,docker-ce-cli软件包是在Docker CE 18.09中引入的。在此之前,docker-ce并未将其作为依赖项。例如,可以通过查看Ubuntu Bionic的Packages文件来进行检查:https://download.docker.com/linux/ubuntu/dists/bionic/stable/binary-amd64/Packages
干杯!
答案 1 :(得分:3)
摆脱错误的唯一方法是不安装docker-ce-cli
$ sudo apt-get install docker-ce=18.06.1~ce~3-0~ubuntu containerd.io
检查版本
$ docker version
Client:
Version: 18.06.1-ce
API version: 1.38
Go version: go1.10.3
Git commit: e68fc7a
Built: Tue Aug 21 17:24:51 2018
OS/Arch: linux/amd64
Experimental: false
Server:
Engine:
Version: 18.06.1-ce
API version: 1.38 (minimum version 1.12)
Go version: go1.10.3
Git commit: e68fc7a
Built: Tue Aug 21 17:23:15 2018
OS/Arch: linux/amd64
Experimental: false