mirror of
https://github.com/getsops/sops.git
synced 2026-02-05 12:45:21 +01:00
Returning stderr when gpg encrypt fails (#762)
Co-authored-by: AJ Bahnken <1144310+ajvb@users.noreply.github.com>
This commit is contained in:
@@ -80,7 +80,7 @@ func (key *MasterKey) encryptWithGPGBinary(dataKey []byte) error {
|
||||
cmd.Stderr = &stderr
|
||||
err := cmd.Run()
|
||||
if err != nil {
|
||||
return err
|
||||
return fmt.Errorf("gpg binary failed with error: %s, %s", err, stderr.String())
|
||||
}
|
||||
key.EncryptedKey = stdout.String()
|
||||
return nil
|
||||
|
||||
Reference in New Issue
Block a user