diff --git a/hack/verify-container-images.sh b/hack/verify-container-images.sh index f9fa68fbf1..51b5d5f546 100755 --- a/hack/verify-container-images.sh +++ b/hack/verify-container-images.sh @@ -24,6 +24,7 @@ fi VERSION=${1} GO_ARCH="$(go env GOARCH)" +DB_MIRROR="public.ecr.aws/aquasecurity/trivy-db" REPO_ROOT=$(git rev-parse --show-toplevel) "${REPO_ROOT}/hack/ensure-trivy.sh" "${VERSION}" @@ -35,7 +36,7 @@ make REGISTRY=gcr.io/k8s-staging-capi-vsphere PULL_POLICY=IfNotPresent TAG=dev d make clean-release-git # Scan the images -"${TRIVY}" image -q --exit-code 1 --ignore-unfixed --severity MEDIUM,HIGH,CRITICAL gcr.io/k8s-staging-capi-vsphere/cluster-api-vsphere-controller-"${GO_ARCH}":dev && R1=$? || R1=$? +"${TRIVY}" image --db-repository="${DB_MIRROR}" -q --exit-code 1 --ignore-unfixed --severity MEDIUM,HIGH,CRITICAL gcr.io/k8s-staging-capi-vsphere/cluster-api-vsphere-controller-"${GO_ARCH}":dev && R1=$? || R1=$? echo "" BRed='\033[1;31m'