Skip to content

feat: add support for trivy media types

Context

The new registry backed by a metadata database only accepts media types registered in the media_types table.

Proposal

Add support for custom media types used by https://github.com/aquasecurity/trivy. Based on https://github.com/aquasecurity/trivy/blob/main/pkg/db/db.go#L20 and https://github.com/aquasecurity/trivy-db/actions/runs/2007792805/workflow#L57, we need to add support for:

  • application/vnd.aquasec.trivy.db.layer.v1.tar+gzip (layers)
  • application/vnd.aquasec.trivy.config.v1+json (config)

This is similar to !942 (merged).