How to add a new GPG public key to gopass?
Because I don’t want to remember this…
- The new member generates a new public key (ex: newbee.pem)
- He/She shares the key somehow (public keyring, slack, jira etc).
Sharing as a file is preferred because it will reduce the likelihood of a bad copy/paste. - A team member needs to add the key to their keychain.
gpg --import newbee.pem
- Then he can to update the gopass recipient list. (This will re-encrypt all secrets)
fp=$(gpg -k newbee@email.com | grep -e '^\s' | tr -d ' ') gopass recipients add ${fp}
- And sync upstream so everyone else knows about it.
gopass sync