1

I'm following this guide, but once I run apt update, I get this error:

GPG error: https://download.docker.com/linux/debian bullseye InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 7EA0A9C3F273FCD8The repository 'https://download.docker.com/linux/debian bullseye InRelease' is not signed.

Any help is appreciated!

Omar
  • 141
  • 1
  • 7
  • Duplicate of https://unix.stackexchange.com/questions/417586/apt-key-management-failure-any-full-online-solution-or-key-download-method ? – Jeff Schaller Dec 05 '21 at 14:31

3 Answers3

3

this works instead

curl -fsSL https://download.docker.com/linux/debian/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg


echo \
  "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian \
  $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
Omar
  • 141
  • 1
  • 7
1

You can also make sure that the gpg file is readable by all users. Mine was not and changing that permission solved the problem, as stated in official Install guide!

1

To complement Marcus' answer:

make sure the permissions are set correctly by the following commands:

sudo chmod a+rx /etc/apt/keyrings
sudo chmod a+r /etc/apt/keyrings/docker.gpg
Thawn
  • 992
  • 6
  • 13
  • 1
    You helped me a lot! Thank you! Docker should update the docs. Tried hours other stuff... – Wie Aug 25 '22 at 21:20