From 5e34eee5b2eaeda69aba39447c3d605250607ff6 Mon Sep 17 00:00:00 2001 From: Ali Mosajjal Date: Sat, 15 Jul 2023 13:52:11 +1200 Subject: [PATCH] updated dockerfile --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index dbe6748..4b58e7f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM --platform=${BUILDPLATFORM:-linux/amd64} golang:1.20.4-alpine3.18 +FROM --platform=${BUILDPLATFORM:-linux/amd64} golang:1.20.6-alpine3.18 ARG TARGETPLATFORM ARG BUILDPLATFORM @@ -11,7 +11,7 @@ RUN mkdir /app ADD . /app/ WORKDIR /app ENV CGO_ENABLED=0 -RUN GOOS=${TARGETOS} GOARCH=${TARGETARCH} go build -ldflags "-s -w -X main.version=$(git describe --tags) -X main.commit=$(git rev-parse HEAD)" -o sniproxy . +RUN GOOS=${TARGETOS} GOARCH=${TARGETARCH} GOFLAGS=-buildvcs=false go build -ldflags "-s -w -X main.version=$(git describe --tags) -X main.commit=$(git rev-parse HEAD)" -o sniproxy . CMD ["/app/sniproxy"] FROM scratch