-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Description
What’s missing?
Add a new Gradle task, policyCheck, that uploads the SBOM (or waits for an existing upload), polls the Dependency-Track API for policy results, and fails the build when violations matching a user-defined status list are found.
Desired behaviour
dependencyTrackCompanion {
policyCheck {
timeout.set(60.seconds) // wait for DT to finish evaluation
failOn.set(listOf(FAIL, WARN)) // default = [FAIL]
}
}- timeout – max wait for policy evaluation (default 0 s).
- failOn – list of violation states that should break the build (INFO, WARN, FAIL; default FAIL).
Acceptance criteria
- Task succeeds when no matching violations exist.
- Task fails (exit 1) if at least one matching violation is present.
- Console shows a short summary: counts per status plus links to the project.
Happy to contribute a PR if this fits the roadmap!
Metadata
Metadata
Assignees
Labels
No labels