← All insightsBest Practices

Trivy best practices for teams

Nir Geier, CodeWizard · 27 March 2026 · 3 min read · Intermediate

Trivy rewards a little discipline. These are the practices that keep it maintainable as a team and a codebase grow.

The practices

  • Gate on HIGH/CRITICAL with ignore-unfixed, then tighten over time
  • Scan images, IaC and filesystems - not just one surface
  • Cache and periodically refresh the DB in CI

What good looks like

Config file to fail only on HIGH/CRITICAL and ignore unfixed CVEs.

yaml
# trivy.yaml
severity:
  - HIGH
  - CRITICAL
vulnerability:
  ignore-unfixed: true
exit-code: 1

Anti-patterns to retire

  • Failing on unfixed CVEs and drowning in noise
  • Scanning only images and ignoring IaC and secrets
  • Never updating the vulnerability DB in air-gapped runners

Want senior help putting Trivy to work - or a team bootcamp on it? CodeWizard runs Israel's largest DevOps community and embeds named senior engineers with a transparent hours log. Book a free consult or explore the Academy.

Like where this is going?

Get hands-on help from the engineers who write these posts.

Book a free consult