Skip to content

Instantly share code, notes, and snippets.

@jpartain89
Created June 8, 2016 01:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jpartain89/e05a2d7efee438e0964ec5f886e091e7 to your computer and use it in GitHub Desktop.
Save jpartain89/e05a2d7efee438e0964ec5f886e091e7 to your computer and use it in GitHub Desktop.
Update Ubuntu APT Keys
#!/bin/bash
# Retrieves missing keys from keyserver.ubuntu.com from user-input pubkey.
# The "pubkey" is the string of letters and numbers that apt-get will spit out
# when the private key isn't saved. Its the "public key," thus "pubkey."
echo "Paste in the GPG Keys that need to be retrieved: "
read -r gpgkey
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys "$gpgkey"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment