I added a new GPG key using this command:
curl -fsSL https://pgp.mongodb.com/server-7.0.asc | \
sudo gpg -o /usr/share/keyrings/mongodb-server-7.0.gpg \
--dearmor
The file is appearing in /usr/share/keyrings/mongodb-server-7.0.gpg
but when I run sudo apt-key list
, there is no entry for it, and it is giving an error while running apt update
. How do I fix this?
/usr/share/keyrings/
and not/etc/apt/keyrings/
. Will this not be a problem? – khateeb Aug 17 '23 at 08:07/usr/share
, so your keyring might conflict if some package somehow adds a file with the exact same path, but again, not likely to happen. – muru Aug 17 '23 at 08:10