From 602238d171a7960df74d382a3413a3dbdf2410f4 Mon Sep 17 00:00:00 2001 From: Stefan Prodan Date: Tue, 9 Aug 2022 12:40:08 +0300 Subject: [PATCH] Add file path to sops decryption errors Signed-off-by: Stefan Prodan --- controllers/kustomization_decryptor.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/controllers/kustomization_decryptor.go b/controllers/kustomization_decryptor.go index 01ca0fea..7365b60c 100644 --- a/controllers/kustomization_decryptor.go +++ b/controllers/kustomization_decryptor.go @@ -621,7 +621,7 @@ func secureLoadKustomizationFile(root, path string) (*kustypes.Kustomization, er }, } if err := yaml.Unmarshal(data, &kus); err != nil { - return nil, fmt.Errorf("failed to unmarshal kustomization file: %w", err) + return nil, fmt.Errorf("failed to unmarshal kustomization file from '%s': %w", loadPath, err) } return &kus, nil }