add-apt-key(8)

πŸ“¦ version 1.0, in ubuntu jammy

πŸ’– add-apt-key(8) β€” the girlies' guide to yeeting GPG keys into your APT keyring πŸ’–

okay so bestie, welcome to add-apt-key, a System Manager's Manual classic. she's a command line tool. she adds GPG keys to the APT keyring. that's the whole vibe. let's get into it 🫢


✨ NAME ✨

add-apt-key β€” Command line tool to add GPG keys to the APT keyring

like. literally what it says on the tin. no cap. πŸ‘‘


🌸 SYNOPSIS 🌸

add-apt-key [ --help ] [ --verbose ] [ --keyserver name ] keyid

πŸ¦‹ DESCRIPTION πŸ¦‹

so add-apt-key goes out, asks a public keyserver real nicely for the GPG key you named, and then slides it into the APT keyring. and once that key is in there? any archive signed with that key is trusted. it's giving trust fall but make it cryptography. πŸ’…


πŸŽ€ OPTIONS πŸŽ€

she follows the usual GNU command line syntax β€” long options get two dashes (--), as is tradition, as is iconic.

  • -h, --help β€” shows the online help (usage). your little "wait what do i type" moment, solved. ✨
  • -v, --verbose β€” verbose mode, which shows each command before it gets executed. so you can watch the whole thing happen in real time like a livestream. πŸ”₯
  • -k, --keyserver name β€” picks a specific keyserver to use. you get to choose your own adventure here, name is the one you're picking.
  • keyid β€” the GPG key identifier to add. this is the whole point of the whole thing. 🫢

πŸ’œ FILES πŸ’œ

  • /etc/default/add-apt-key β€” configuration file specifying the public keyserver to use. it's the vibe-setter file. set it and forget it. 🌈

🌟 EXIT VALUES 🌟

the folling exit values are used β€” here's your lil cheat sheet for when she leaves:

  1. 0 β€” Adding the keyid was successful. πŸŽ‰ slay.
  2. 1 β€” Invalid script arguments. πŸ™ˆ you typed something weird bestie.
  3. 2 β€” GPG keyid cannot be retrieved (or is malformed). πŸ’€ the keyserver said no, or the thing you gave her is shaped wrong.
  4. 3 β€” Error in adding keyid to the APT keyring. 😭 so close, and yet.
lowkey important: 0 means good, everything else means something went sideways. check the number, don't just assume it worked. periodt.

🧚 SEE ALSO 🧚


okay that's the whole page, you're so welcome πŸ’– this was a System Administration Commands situation, dated 2007-02-02, and the whole thing lives under the name add-apt-key(8). go forth and add those keys, bestie. mwah. πŸ’…πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from