Skip to content

Commit

Permalink
Remove newlines from ssh output; #136
Browse files Browse the repository at this point in the history
  • Loading branch information
robertauer committed Nov 27, 2024
1 parent a32591f commit 122c87d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/com/cloudogu/ces/cesbuildlib/Trivy.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,8 @@ class Trivy implements Serializable {
String additionalFlags = "--db-repository public.ecr.aws/aquasecurity/trivy-db --java-db-repository public.ecr.aws/aquasecurity/trivy-java-db",
String trivyReportFile = "trivy/trivyReport.json"
) {
String image = script.sh(script: "jq .Image ${doguDir}/dogu.json", returnStdout: true)
String version = script.sh(script: "jq .Version ${doguDir}/dogu.json", returnStdout: true)
String image = script.sh(script: "jq .Image ${doguDir}/dogu.json", returnStdout: true).trim()
String version = script.sh(script: "jq .Version ${doguDir}/dogu.json", returnStdout: true).trim()
return scanImage(image+":"+version, severityLevel, strategy, additionalFlags, trivyReportFile)
}

Expand Down

0 comments on commit 122c87d

Please sign in to comment.