This commit is contained in:
committer@tuxwarrior
2026-02-24 18:35:15 -05:00
parent 56a2aa7cc9
commit 8f9f25bf72
12 changed files with 158 additions and 36 deletions

View File

@@ -2,19 +2,30 @@
# klevstul :: 24.06
# ---------------------------------------------------------------------------------------------------------------------
# how to backup gpg:
# gpg --export --export-options backup --output public.gpg frode@thisworld.is
# gpg --export-secret-keys --export-options backup --output private.gpg frode@thisworld.is
# ref: https://www.howtogeek.com/816878/how-to-back-up-and-restore-gpg-keys-on-linux/
#
# new method:
# cp /home/poq/.gnupg/
# gpg --armor --export frode@klevstul.com > /home/poq/.local/share/Cryptomator/mnt/cryptLocal/content/keys/openPgp/.gnupg/251110_frodeKlevstul_publicKey.asc
# gpg --armor --export-secret-keys frode@klevstul.com > /home/poq/.local/share/Cryptomator/mnt/cryptLocal/content/keys/openPgp/.gnupg/251110_frodeKlevstul_privateKey.asc
#
# old method:
# gpg --export --export-options backup --output public.gpg frode@thisworld.is
# gpg --export-secret-keys --export-options backup --output private.gpg frode@thisworld.is
# ref: https://www.howtogeek.com/816878/how-to-back-up-and-restore-gpg-keys-on-linux/
# ---------------------------------------------------------------------------------------------------------------------
this_file_name=`basename "$0"`
echo "$this_file_name"
echo "please, remember the hint: poq.l2"
# location of ssh keys
syncdir_env_var=SYNCDIR_${HOSTNAME}
src_gnupg_dir=${!syncdir_env_var}/secrets/gnupg
gpg --import ${src_gnupg_dir}/public.gpg
gpg --import ${src_gnupg_dir}/private.gpg
gpg --import ${src_gnupg_dir}/*publicKey.asc
gpg --import ${src_gnupg_dir}/*privateKey.asc
gpg --list-secret-keys --keyid-format LONG