feat: make trivy scan cause build to fail configurable

This commit is contained in:
Stefan Reimer 2022-02-14 12:52:49 +01:00
parent ba73be47cc
commit ba21a45551
1 changed files with 1 additions and 1 deletions

View File

@ -49,7 +49,7 @@ def call(Map config) {
]
// Scan again and fail on CRITICAL vulns
sh 'TRIVY_EXIT_CODE=1 TRIVY_SEVERITY=CRITICAL make scan'
sh '[ "${config.trivyFail}" == "NONE" ] || TRIVY_EXIT_CODE=1 TRIVY_SEVERITY=${config.trivyFail} make scan'
}
}