问题
I have an encrypted file with gpg that I want to decrypt from inside a docker container. gpg is not found on the container, how would I add it.
回答1:
Depending on your base image (used by your container), you would need to add to your Dockerfile
(or to make one, starting with FROM <the image used by your container>
) with:
RUN apt-get update && apt-get install gnupg
(as in this docker-vault-init Dockerfile)
Then check out "Adding GPG key inside docker container causes “no valid OpenPGP data found”".
This could be needed:
RUN apt-get install -y ca-certificates wget
来源:https://stackoverflow.com/questions/37519303/decrypt-with-gpg-from-inside-a-docker-container