Files
volume/examples/distroless/Dockerfile.helper
T
zeekayandHanzo Dev 61bfa3f65a go 1.26.8
One toolchain across the estate. The tree carried 1.26.0, .1, .3, .4 and .5
at once, so which compiler built a binary depended on which repo it came
from.

Co-authored-by: Hanzo Dev <[email protected]>
2026-09-08 23:52:45 -07:00

14 lines
297 B
Docker

FROM golang:1.26.8-alpine AS builder
COPY main.go /main.go
COPY go.mod /go.mod
RUN cd / && CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags "-extldflags -static -s -w" -o /manager && \
chmod 777 /manager
FROM scratch
COPY --from=builder /manager /manager
ENTRYPOINT [ "/manager" ]