From 2104171b4f9a8ed02bae6c8218bd1c4f502bb2ed Mon Sep 17 00:00:00 2001 From: Vishal Choudhary Date: Thu, 6 Jun 2024 17:21:01 +0530 Subject: [PATCH] fix: add verbosity to background scanner log (#10404) Signed-off-by: Vishal Choudhary --- pkg/controllers/report/utils/scanner.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/controllers/report/utils/scanner.go b/pkg/controllers/report/utils/scanner.go index 542e01188814..1dd597d06f90 100644 --- a/pkg/controllers/report/utils/scanner.go +++ b/pkg/controllers/report/utils/scanner.go @@ -118,7 +118,7 @@ func (s *scanner) validateResource(ctx context.Context, resource unstructured.Un WithNamespaceLabels(nsLabels) response := s.engine.Validate(ctx, policyCtx) if len(response.PolicyResponse.Rules) > 0 { - s.logger.Info("validateResource", "policy", policy, "response", response) + s.logger.V(6).Info("validateResource", "policy", policy, "response", response) } return &response, nil } @@ -140,7 +140,7 @@ func (s *scanner) validateImages(ctx context.Context, resource unstructured.Unst WithNamespaceLabels(nsLabels) response, _ := s.engine.VerifyAndPatchImages(ctx, policyCtx) if len(response.PolicyResponse.Rules) > 0 { - s.logger.Info("validateImages", "policy", policy, "response", response) + s.logger.V(6).Info("validateImages", "policy", policy, "response", response) } return &response, nil }