2022-11-03 11:04:20 +03:00
|
|
|
ARG GOLANG_VERSION="1.19.1"
|
2019-11-20 21:56:33 +03:00
|
|
|
|
2020-03-21 22:32:41 +03:00
|
|
|
FROM golang:$GOLANG_VERSION-alpine as builder
|
2021-07-07 14:17:44 +03:00
|
|
|
RUN apk --no-cache add tzdata
|
|
|
|
WORKDIR /go/src/github.com/serjs/socks5
|
2018-04-15 21:08:32 +03:00
|
|
|
COPY . .
|
2018-04-16 09:24:35 +03:00
|
|
|
RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -ldflags '-s' -o ./socks5
|
2018-04-15 21:08:32 +03:00
|
|
|
|
2022-11-03 11:04:20 +03:00
|
|
|
FROM gcr.io/distroless/static:nonroot
|
2021-07-07 14:17:44 +03:00
|
|
|
COPY --from=builder /go/src/github.com/serjs/socks5/socks5 /
|
2024-01-13 09:22:40 +03:00
|
|
|
|
2018-04-15 21:08:32 +03:00
|
|
|
ENTRYPOINT ["/socks5"]
|