背景:我正在使用 pop os 22.04
我曾尝试通过shell脚本下载方法安装docker:
$ sudo curl -sSL https://get.docker.com/ | sh
失败并显示以下消息
# Executing docker install script, commit: b2e29ef7a9a89840d2333637f7d1900a83e7153f
+ sudo -E sh -c apt-get update -qq >/dev/null
E: The repository 'https://download.docker.com/linux/debian bookworm Release' does not have a Release file.
现在,当我尝试使用时apt update
出现此错误:
Hit:1 http://us.archive.ubuntu.com/ubuntu jammy InRelease
Hit:2 http://us.archive.ubuntu.com/ubuntu jammy-security InRelease
Hit:3 http://apt.pop-os.org/proprietary jammy InRelease
Hit:4 http://us.archive.ubuntu.com/ubuntu jammy-updates InRelease
Hit:5 http://us.archive.ubuntu.com/ubuntu jammy-backports InRelease
Ign:6 https://download.docker.com/linux/debian bookworm InRelease
Err:7 https://download.docker.com/linux/debian bookworm Release
404 Not Found [IP: 108.138.199.73 443]
Hit:8 http://apt.pop-os.org/release jammy InRelease
Reading package lists... Done
E: The repository 'https://download.docker.com/linux/debian bookworm Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details
我尝试通过 apt 卸载它,但它无法识别 docker 或它的任何名称变体。
我如何安全地删除我下载的不完整包的文件?
答案1
我知道这个问题一开始就不是主题,但这个答案对于 ubuntu 用户来说可能很有用:
问题不在于我下载的任何单个文件,而在于安装添加了https://download.docker.com/linux/debian到我的包管理器的源列表,由于检查不兼容的 Debian 版本而发生错误。从我的源列表中删除链接后,它apt update
已恢复正常工作。