Scan faster. Secure smarter.
This is a high-performance, Node.js-based GitHub Action for Trivy. Unlike standard container-based actions, this runs directly on the runner VM, offering lightning-fast startup times, intelligent database caching, and clean Job Summaries.
Automated Vulnerbility Scanning π
| Feature | Official Trivy Action | This Ultimate Action |
|---|---|---|
| Startup Speed | π’ Slow (Pulls Docker Image) | β‘ Instant (Node.js Native) |
| Database Caching | β Manual Setup | β Automatic (Daily Cache) |
| UX | Console Logs only | β Rich Job Summaries |
| Architecture | x64 Only | β x64 & ARM64 Support |
| Audit Ready | β Manual | β Auto-uploads Artifacts |
- β‘ Lightning Fast: Built with Node 20, bypassing heavy container pulls.
- π¦ Smart Caching: Automatically caches the Trivy Database (DB) to save minutes on every run.
- π Rich Summaries: Generates a clean security overview directly on your GitHub Actions summary page.
- π‘οΈ Security Tab Integration: Full SARIF support to show vulnerabilities in your PR "Files Changed" tab.
- π SBOM Generation: Create CycloneDX or SPDX bill-of-materials with a single flag.
- π οΈ Compliance Ready: Support for CIS Benchmarks, NSA, and more.
Add this to your .github/workflows/security.yml:
- name: π‘οΈ Run Security Scan
uses: anantacloud-actions/trivy@v1
with:
scan-type: 'fs'
severity: 'HIGH,CRITICAL'Don't dig through logs! This action generates a professional summary at the end of every run.
Target:
.| Type:fs
Severity Count Fixed π΄ CRITICAL 2 2 π HIGH 5 3 β No vulnerabilities found with current threshold. (or
β οΈ Action failed due to 7 vulnerabilities)
| Input | Description | Default |
|---|---|---|
scan-type |
Type of scan: fs, image, config, sbom |
fs |
scan-target |
Target to scan (path . or image name) |
. |
severity |
Severities (LOW,MEDIUM,HIGH,CRITICAL) |
HIGH,CRITICAL |
exit-code |
Exit code when vulnerabilities are found (1 to fail) |
0 |
format |
Output format: table, json, sarif |
table |
trivy-version |
Specific version or latest |
latest |
upload-artifact |
Automatically upload the report as a workflow artifact | true |
If you find this action useful, please consider giving it a β Star on GitHub!
Distributed under the MIT License.