some read-only operations appear to fail for gpg when the gnupg homedir is not
writable.
For example:
export GNUPGHOME=$(mktemp -d)
gpg --list-keys # initialize
gpg --recv 0x249B39D24F25E3B6
gpg --list-keys
chmod u-w $GNUPGHOME $GNUPGHOME/*
gpg --list-keys
This can be worked around with --lock-never, but it seems clumsy to have to do
this when the command is read-only in the first place.
This came up at https://bugs.debian.org/771976, where a user had a debian system
with a read-only /etc, and tried to do "apt-key list", which is something that
should really work.