cloudnativedevops / demo

Simple demonstration app for 'Cloud Native Devops'
MIT License
799 stars 517 forks source link

Sops example error #20

Closed jhagege closed 4 years ago

jhagege commented 4 years ago

Hi, I'm trying to run the sops example, but I get the following error:

Group 0: FAILED
  8252CFC3A36E12F7214687F44E66A6921AAADBBF: FAILED
    - | could not decrypt data key with PGP key:
      | golang.org/x/crypto/openpgp error: Could not load secring:
      | open /Users/joachimhagege/.gnupg/secring.gpg: no such file
      | or directory; GPG binary error: exit status 2

Recovery failed because no master key was able to decrypt the file. In
order for SOPS to recover the file, at least one key has to be successful,
but none were.

Do I need to provide a specific key ? Thanks.

bitfield commented 4 years ago

Hi @jhagege! Thanks for the report!

It looks like GnuPG can't find your keyring. Did you generate a keypair using gpg --gen-key as described in the book? Come to that, did you manage to successfully encrypt the file? If you can do that, you ought to be able to decrypt it too, oughtn't you?

Can you try running through the complete sequence in the 'Encrypting a file with sops' section, and copy and paste here each command you run and the output that you see. That should help us figure out what's going wrong.

domingusj commented 4 years ago

Closing to clean up old issues, but reply back if you think this is unresolved and want to continue discussing.