Debian11
宝塔面板Docker管理器安装以后apt update
会发出现错误:
W: GPG error: https://download.docker.com/linux/ubuntu bionic InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 7EA0A9C3F273FCD8
E: The repository 'https://download.docker.com/linux/ubuntu bionic InRelease' is not signed.
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.
参考资料,执行如下:
root@debian:~# gpg --keyserver pgpkeys.mit.edu --recv-key 9AA38DCD55BE302B
得到:
gpg: directory '/root/.gnupg' created
gpg: keybox '/root/.gnupg/pubring.kbx' created
gpg: /root/.gnupg/trustdb.gpg: trustdb created
gpg: key 9AA38DCD55BE302B: public key "Debian Archive Automatic Signing Key (5.0/lenny) <ftpmaster@debian.org>" imported
gpg: Total number processed: 1
gpg: imported: 1
尝试apt update
后错误依旧。
参考资料二
root@debian:~# curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
-bash: sudo: command not found
(23) Failed writing body
安装sudo:
root@debian:~# apt install sudo
然后
root@debian:~# curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
再执行apt update
,居然不报错了。俺不知道为啥,都是复制的,反正解决了,俺是实在人,U1S1。
One comment
这权限就很玄学,另外,博主是不是该更新以下你的SSL证书了。