diff --git a/Dockerfile b/Dockerfile index 4ce5bc9..27dc6e5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,8 @@ -FROM golang:alpine as builder +FROM golang:alpine AS builder WORKDIR /go -RUN go install github.com/xvzc/SpoofDPI/cmd/spoofdpi@latest +RUN go install -ldflags '-w -s -extldflags "-static"' -tags timetzdata github.com/xvzc/SpoofDPI/cmd/spoofdpi@latest -FROM gcr.io/distroless/static-debian12 +FROM scratch +COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ COPY --from=builder /go/bin/spoofdpi / ENTRYPOINT ["/spoofdpi"]