2025-12-12 12:55:39 +06:00
|
|
|
FROM alpine:3.23.0
|
2022-07-11 18:49:55 +06:00
|
|
|
RUN apk --no-cache add ca-certificates git
|
|
|
|
|
|
|
|
|
|
# binaries were created with GoReleaser
|
|
|
|
|
# need to copy binaries from folder with correct architecture
|
|
|
|
|
# example architecture folder: dist/trivy_canary_build_linux_arm64/trivy
|
2025-08-07 17:31:33 +02:00
|
|
|
# GoReleaser adds _v* to the folder name, but only when GOARCH is amd64
|
2022-07-11 18:49:55 +06:00
|
|
|
ARG TARGETARCH
|
2023-04-13 13:27:06 +06:00
|
|
|
COPY "dist/trivy_canary_build_linux_${TARGETARCH}*/trivy" /usr/local/bin/trivy
|
2022-07-11 18:49:55 +06:00
|
|
|
COPY contrib/*.tpl contrib/
|
|
|
|
|
ENTRYPOINT ["trivy"]
|