Update docker/trivy/start.sh
ci/woodpecker/push/woodpecker Pipeline was successful Details

This commit is contained in:
colin 2024-01-20 20:59:53 +00:00
parent 28ae0e17e0
commit eaf9ef4009
1 changed files with 2 additions and 2 deletions

View File

@ -57,10 +57,10 @@ report_scan_results() {
run_scan() {
if [ "$LOW_PRIORITY" = "true" ]; then
echo "Running Trivy scan with low priority (nice 19)..."
nice -n 19 trivy filesystem --skip-update --timeout $TIMEOUT --scanners $SCANNERS $( [ "$IGNORE_UNFIXED" = "true" ] && echo '--ignore-unfixed' ) /mnt > $CURRENT_LOG
nice -n 19 trivy filesystem --skip-update --config $CURRENT_LOG --timeout $TIMEOUT --scanners $SCANNERS $( [ "$IGNORE_UNFIXED" = "true" ] && echo '--ignore-unfixed' ) /mnt
else
echo "Running Trivy scan..."
trivy filesystem --skip-update --timeout $TIMEOUT --scanners $SCANNERS $( [ "$IGNORE_UNFIXED" = "true" ] && echo '--ignore-unfixed' ) /mnt > $CURRENT_LOG
trivy filesystem --skip-update --config $CURRENT_LOG --timeout $TIMEOUT --scanners $SCANNERS $( [ "$IGNORE_UNFIXED" = "true" ] && echo '--ignore-unfixed' ) /mnt
fi
}