Skip to content

Commit

Permalink
JSON.stringify findings details output + minimal docs
Browse files Browse the repository at this point in the history
  • Loading branch information
andrzej3393 authored and alexjurkiewicz committed Dec 22, 2022
1 parent 51922b8 commit bc9b97b
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ Scan an image uploaded to ECR and fail if vulnerabilities are found.
| low | Number of low vulnerabilities detected. |
| informational | Number of informational vulnerabilities detected. |
| unknown | Number of unknown vulnerabilities detected. |
| findingsDetails | Details of findings. |

## Required ECR permissions

Expand Down
2 changes: 2 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ outputs:
description: Number of unknown severity vulnerabilities detected.
total:
description: Total number of vulnerabilities detected.
findingsDetails:
description: Details of findings.
runs:
using: "docker"
image: "Dockerfile"
Expand Down
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ const main = async () => {
const indeterminate = counts.UNDEFINED || 0
const ignored = ignoredFindings.length
const total = critical + high + medium + low + informational + indeterminate
core.setOutput('findingsDetails', findingsDetails.toString())
core.setOutput('findingsDetails', JSON.stringify(findingsDetails))
core.setOutput('critical', critical.toString())
core.setOutput('high', high.toString())
core.setOutput('medium', medium.toString())
Expand Down

0 comments on commit bc9b97b

Please sign in to comment.