Skip to content
Snippets Groups Projects
Commit e3a95408 authored by Pierre Smeyers's avatar Pierre Smeyers
Browse files

fix(Trivy): Trivy 0.53.0 added the clean subcommand for semantic cache management

parent aa0b7a0c
No related branches found
No related tags found
No related merge requests found
......@@ -930,7 +930,7 @@ docker-trivy:
TRIVY_CACHE_DIR: ".trivycache/"
script: |
# cache cleanup is needed when scanning images with the same tags, it does not remove the database
trivy image --clear-cache
trivy clean --scan-cache || trivy image --clear-cache
export TRIVY_USERNAME=${DOCKER_REGISTRY_SNAPSHOT_USER:-${DOCKER_REGISTRY_USER:-$CI_REGISTRY_USER}}
export TRIVY_PASSWORD=${DOCKER_REGISTRY_SNAPSHOT_PASSWORD:-${DOCKER_REGISTRY_PASSWORD:-$CI_REGISTRY_PASSWORD}}
basename=$(echo "${DOCKER_SNAPSHOT_IMAGE}" | sed 's|[/:]|_|g')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment