From f1dada82d8d32532cd48ea11b837ccd3122ce4d5 Mon Sep 17 00:00:00 2001 From: chenk Date: Thu, 30 May 2024 09:35:13 +0300 Subject: [PATCH] fix: non completed containers with invalid stacktrace (#2107) Signed-off-by: chenk --- .gitignore | 2 ++ pkg/vulnerabilityreport/controller/scanjob.go | 2 -- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index ef0504ade..87b035400 100644 --- a/.gitignore +++ b/.gitignore @@ -22,3 +22,5 @@ output/* ## yamllint logfile yamllint-* kubeconfig +## policies folder +cmd/trivy-operator/tmp/ \ No newline at end of file diff --git a/pkg/vulnerabilityreport/controller/scanjob.go b/pkg/vulnerabilityreport/controller/scanjob.go index b5bdca946..0ddd8f139 100644 --- a/pkg/vulnerabilityreport/controller/scanjob.go +++ b/pkg/vulnerabilityreport/controller/scanjob.go @@ -349,8 +349,6 @@ func (r *ScanJobController) completedContainers(ctx context.Context, scanJob *ba } if strings.Contains(status.Message, "no child with platform linux") { log.Info("Scan job container", "container", container, "status.reason", status.Reason, "status.message", "Scanning Windows images is not supported.") - } else { - log.Error(nil, "Scan job container", "container", container, "status.reason", status.Reason, "status.message", status.Message) } } return completedContainers, nil