Trivy Configuration Reference
This page provides a complete reference of all configuration properties available in the trivy { } block.
Global Configuration
The trivy block is located at kreate { project { trivy { ... } } }.
Property | Type | Default | Description |
|---|---|---|---|
|
|
| Enables or disables the Trivy module for the project. |
|
| - | Configuration for license scanning. |
|
| - | Configuration for vulnerability scanning. |
|
| - | Configuration for secret scanning. |
License Scanning (license { })
Property | Type | Default | Description |
|---|---|---|---|
|
|
| Fails the build if forbidden licenses are detected. |
|
|
| Severities to include in the scan. |
|
|
| List of licenses to ignore (e.g., "MIT", "Apache-2.0"). |
|
|
| The collection of lockfiles to be scanned. |
Vulnerability Scanning (vulnerability { })
Property | Type | Default | Description |
|---|---|---|---|
|
|
| Fails the build if vulnerabilities are detected. |
|
|
| Vulnerability scores to include in the scan. |
|
|
| The collection of lockfiles to be scanned. |
Secret Scanning (secrets { })
Property | Type | Default | Description |
|---|---|---|---|
|
|
| Fails the build if secrets are detected. |
|
|
| Severities of secrets to include. |
|
|
| Path to the Trivy secret configuration file. |
|
| (src/**/*.kt, etc.) | The files to be scanned for secrets. |
Enums Reference
LicenseSeverity
CRITICAL, HIGH, MEDIUM, LOW, UNKNOWN
Score (Vulnerability)
CRITICAL, HIGH, MEDIUM, LOW
SecretSeverity
CRITICAL, HIGH, MEDIUM, LOW