CI: check ubuntu and alpine images with trivy (#22314)

* CI: check ubuntu and alpine images with trivy

* CI: clear trivy cache before running
This commit is contained in:
Leonard Gram 2020-02-19 16:10:22 +01:00 committed by GitHub
parent b148b306e2
commit d5a2bc1a54
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1898,8 +1898,14 @@ jobs:
tar zxvf trivy_${VERSION}_Linux-64bit.tar.gz tar zxvf trivy_${VERSION}_Linux-64bit.tar.gz
sudo mv trivy /usr/local/bin sudo mv trivy /usr/local/bin
- run: - run:
name: Scan the latest grafana master image with trivy name: Clear trivy cache
command: trivy --exit-code 1 --quiet --auto-refresh --clear-cache grafana/grafana:master command: trivy --clear-cache
- run:
name: Scan the latest grafana master alpine image with trivy
command: trivy --exit-code 1 grafana/grafana:master
- run:
name: Scan the latest grafana master ubuntu image with trivy
command: trivy --exit-code 1 grafana/grafana:master-ubuntu
- save_cache: - save_cache:
key: vulnerability-db key: vulnerability-db
paths: paths: