我遵循了docker官方教程https://docs.docker.com/engine/install/ubuntu/中的指导原则,指向Install using the repository,但在将新的apt源条目添加到/etc/apt/Soures.list.d/docker.list之后
deb [arch=amd64] signed=by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian stretch stable尝试调用apt-get update时,我得到了这个:
root@aruba-cloud:~/mgr-project# apt-get update
Ign:1 http://ftp.uk.debian.org/debian stretch InRelease
Hit:2 http://security.debian.org/debian-security stretch/updates InRelease
Hit:3 http://ftp.uk.debian.org/debian stretch-updates InRelease
Hit:4 http://ftp.uk.debian.org/debian stretch Release
Reading package lists... Done
E: The method driver /usr/lib/apt/methods/https could not be found.
N: Is the package apt-transport-https installed?
E: Failed to fetch https://download.docker.com/linux/debian/dists/stretch/InRelease
E: Some index files failed to download. They have been ignored, or old ones used instead.我添加了Docker的官方GPG密钥,因此根据教程,这种情况应该不会发生。我的问题是--我做错了什么?
发布于 2021-11-05 20:53:19
您必须先安装apt-transport-https和ca-certificates包。
apt-get install apt-transport-https ca-certificates如果这不起作用,您必须手动修复您的/etc/apt/sources.list.d/。
https://stackoverflow.com/questions/69858632
复制相似问题