Files
moby/hack/dockerfiles/govulncheck.Dockerfile
Sebastiaan van Stijn d24eab928b update to go1.24.9
go1.24.9 (released 2025-10-13) includes fixes to the crypto/x509 package.
See the Go 1.24.9 milestone on our issue tracker for details:

- https://github.com/golang/go/issues?q=milestone%3AGo1.24.9+label%3ACherryPickApproved
- full diff: https://github.com/golang/go/compare/go1.24.8...go1.24.9

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-11-04 11:05:26 +01:00

27 lines
661 B
Docker

# syntax=docker/dockerfile:1
ARG GO_VERSION=1.24.9
ARG GOVULNCHECK_VERSION=v1.1.4
ARG FORMAT=text
FROM golang:${GO_VERSION}-alpine AS base
WORKDIR /go/src/github.com/docker/docker
RUN apk add --no-cache jq moreutils
ARG GOVULNCHECK_VERSION
RUN --mount=type=cache,target=/root/.cache \
--mount=type=cache,target=/go/pkg/mod \
go install golang.org/x/vuln/cmd/govulncheck@$GOVULNCHECK_VERSION
FROM base AS run
ARG FORMAT
RUN --mount=type=bind,target=.,rw <<EOT
set -ex
mkdir /out
ln -s vendor.mod go.mod
ln -s vendor.sum go.sum
govulncheck -format ${FORMAT} ./... | tee /out/govulncheck.out
EOT
FROM scratch AS output
COPY --from=run /out /