kustomize-controller icon indicating copy to clipboard operation
kustomize-controller copied to clipboard

Cryptic message when GPG binary is not present.

Open gecube opened this issue 9 months ago • 2 comments

Good day!

I was playing around with wolfi hardened images. And they are damn good, small footprint etc. The issue is that guys forgot to add GnuPG binary to docker image, so kustomisation controller stopped decrypt sops secrets:

Unfortunately, the error message is relatively cryptic.

{"level":"error","ts":"2023-09-15T06:15:59.169Z","msg":"Reconciliation failed after 108.87798ms, next try in 5m0s","controller":"kustomization","controllerGroup":"kustomize.toolkit.fluxcd.io","controllerKind":"Kustomization","Kustomization":{"name":"monitoring","namespace":"flux-system"},"namespace":"flux-system","name":"monitoring","reconcileID":"bacf1ab6-e88d-4bea-b31c-f61823717210","revision":"main@sha1:b999ca91832509e0b1acc490f249f7d4dd7827e7","error":"failed to import 'sops.asc' data from sops decryption Secret 'flux-system/sops-gpg': failed to import armored key data into GnuPG keyring: "}

I am expecting additional details after "failed to import armored key data into GnuPG keyring: " like "executable not found" or something that can lead to the root cause of the issue.

I am kindly asking to improve error reporting inside of kustomization controller.

Also the issue with GPG was reported to wolfi/chainguard team: https://github.com/chainguard-images/images/issues/1384

gecube avatar Sep 15 '23 12:09 gecube