add trivy stage
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed

This commit is contained in:
2024-02-07 22:51:24 +01:00
parent 144f8412fa
commit 69f0973319
2 changed files with 9 additions and 2 deletions

View File

@ -2,7 +2,7 @@ steps:
build:
image: plugins/kaniko
settings:
repo: gitea.hottis.de/wn/locsrv
repo: ${FORGE_NAME}/${CI_REPO}
registry:
from_secret: container_registry
tags: latest,${CI_COMMIT_SHA},${CI_COMMIT_TAG}
@ -14,6 +14,13 @@ steps:
when:
- event: [push, tag]
scan_image:
image: aquasec/trivy
commands:
- trivy image $FORGE_NAME/$CI_REPO:$CI_COMMIT_SHA --quiet --exit-code 1
when:
- event: [push, tag]
deploy:
image: portainer/kubectl-shell:latest
secrets:

View File

@ -6,7 +6,7 @@ if [ "$IMAGE_TAG" == "" ]; then
fi
IMAGE_NAME=gitea.hottis.de/wn/locsrv
IMAGE_NAME=$FORGE_NAME/$CI_REPO
NAMESPACE=homea
DEPLOYMENT_DIR=$PWD/deployment