Archive to AWS Glacier with File Encryption

There was a need to start archiving things to AWS Glacier as part of a disaster-recovery initiative. I wrote a bash script to take a target directory, archive it with tar and gzip, encrypt it with gpg, split it into 4GiB chunks, and upload it to Glacier.  The script can also handle < 4GiB objects;…