在 Linux 上安装 Docker 时出现问题:E: "https://download.docker.com/linux/ubuntu una Release" 存储库没有发布文件

Problems installing Docker on Linux: E: The "https://download.docker.com/linux/ubuntu una Release" repository does not have a Release file

我使用 official guideLinux Mint Una 上安装了 Docker 引擎。一切似乎都很好。稍后当我尝试更新时出现错误:

W: "stable / source / Sources" file acquisition skipped as the repository "https://download.docker.com/linux/ubuntu focal InRelease" does not seem to provide this file (wrong sources.list entry?)

E: The "https://download.docker.com/linux/ubuntu una Release" repository does not have a Release file.

PS:不要把问题移到 Ubuntu,因为他们会说这不是 Ubuntu(即使 Linux Mint基于 Ubuntu),他们会将其删除。谢谢

如何解决?谢谢

我遇到了同样的问题。在 Linux Mint 20.X 上,您无法使用存储库安装 docker。相反,按照 this paragraph of the official documentation.

中的说明从 .deb 包安装它

基本上您需要下载 3 个 .deb 文件:containerd.io、docker-ce-cli 和 docker-ce。有多个版本,所以请选择最新的(确保您在同一天获得所有 3 个版本,否则稍后可能会遇到一些问题)。

然后使用 dpkg -i {deb 文件}(根据官方说明)安装,首先是 containerd.io,然后是 docker-ce-cli,最后是 docker-ce(有依赖关系,它会抱怨如果您尝试以错误的顺序安装)。

那就一定要关注the post-installation instructions

编辑:忽略上面的所有内容!! 从软件包安装导致在安装 docker 与 apt-get install docker-compose 组合后出现另一个问题。

欢迎来到精彩的 linux 世界。真是一团糟。没有任何效果,但是嘿,它是免费的!

Ubuntu 的官方 docker 安装文档告诉您三种路径:从存储库安装、从软件包安装和使用便捷脚本安装。

第一条路径不适用于 Linux Mint 20.X,因为 $(lsb_release -cs) returns una (Mint 20.3) uma (20.2)、ulyssa (20.1) 或 ulyana (20.0) 和 none 似乎正在使用官方 docker 中提到的软件包存储库文档。您可以按照文档中的说明快速找到并 运行ning sudo apt update.

一个正常人然后尝试第二条路。根据文档,他们手动下载软件包并使用 dpkg -i 安装它们。我这样做了并且成功了,但是在安装 docker-compose 和 sudo apt install docker-compose 之后,一切都崩溃了。我浪费了很多时间来弄清楚发生了什么。

原来这个命令sudo apt install docker-compose安装了你需要的一切。它安装 docker-ce、docker-ce-cli 和 containerd.io 包,当然还有 docker-compose。如果您有以前的版本(与 dpkg -i 手动安装,它们会发生冲突,docker.service 会被屏蔽)

事实证明这些包在官方 ubuntu 存储库中,所以官方文档中的所有这 3 个安装路径都没有任何意义。安装一切的正确方法是 运行 sudo apt install docker-compose