From 51574e8274a926bb4618c19581842e2cc7d437b6 Mon Sep 17 00:00:00 2001 From: Evgeniy Kulikov Date: Tue, 25 Feb 2020 18:39:35 +0300 Subject: [PATCH] add more debug information to build --- Dockerfile | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 99cad69..3777b08 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,16 +6,17 @@ ARG REPO=github.com/nspcc-dev/neofs-gw ENV GOGC off ENV CGO_ENABLED 0 -ENV LDFLAGS "-w -s -X main.Version=${VERSION}" +# add later -w -s +ENV LDFLAGS " -X main.Version=${VERSION} -compressdwarf=false" WORKDIR /src COPY . /src -RUN go build -v -mod=vendor -trimpath -ldflags "${LDFLAGS} -X main.Build=$(date -u +%s%N)" -o /go/bin/neofs-gw ./ +RUN go build -v -mod=vendor -trimpath -gcflags=all="-N -l" -ldflags "${LDFLAGS} -X main.Build=$(date -u +%s%N)" -o /go/bin/neofs-gw ./ # Executable image -FROM scratch +FROM alpine WORKDIR /