From d2884b893688e1f4eaa2612e308fbee0cb53ce8a Mon Sep 17 00:00:00 2001 From: dwertent Date: Thu, 13 Jan 2022 13:07:29 +0200 Subject: [PATCH] update failure message --- resultshandling/reporter/v1/reporteventreceiver.go | 2 +- resultshandling/reporter/v2/reporteventreceiver.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/resultshandling/reporter/v1/reporteventreceiver.go b/resultshandling/reporter/v1/reporteventreceiver.go index ce197254..fa774983 100644 --- a/resultshandling/reporter/v1/reporteventreceiver.go +++ b/resultshandling/reporter/v1/reporteventreceiver.go @@ -45,7 +45,7 @@ func (report *ReportEventReceiver) ActionSendReport(opaSessionObj *cautils.OPASe return nil } if report.clusterName == "" { - report.message = "WARNING: Failed to publish results. Reason: Unknown cluster name. Run kubescape with the '--kube-context ' flag" + report.message = "WARNING: Failed to publish results because the cluster name is Unknown. If you are scanning YAML files the results are not submitted to the Kubescape SaaS" return nil } diff --git a/resultshandling/reporter/v2/reporteventreceiver.go b/resultshandling/reporter/v2/reporteventreceiver.go index 01927537..443e60e1 100644 --- a/resultshandling/reporter/v2/reporteventreceiver.go +++ b/resultshandling/reporter/v2/reporteventreceiver.go @@ -46,7 +46,7 @@ func (report *ReportEventReceiver) ActionSendReport(opaSessionObj *cautils.OPASe return nil } if report.clusterName == "" { - report.message = "WARNING: Failed to publish results. Reason: Unknown cluster name. Run kubescape with the '--kube-context ' flag" + report.message = "WARNING: Failed to publish results because the cluster name is Unknown. If you are scanning YAML files the results are not submitted to the Kubescape SaaS" return nil } opaSessionObj.Report.ReportID = uuid.NewV4().String()