From 27d4a3b5fc997cda9c9e698b81e452a4475a93c8 Mon Sep 17 00:00:00 2001 From: Quentin McGaw Date: Thu, 18 Oct 2018 15:32:39 +0200 Subject: [PATCH] Fixed Dockerfile (forgot go get) --- Dockerfile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index c245a0b..f020997 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,7 +10,8 @@ FROM golang:alpine AS server RUN apk --update add git build-base upx WORKDIR /go/src/app COPY main.go ./ -RUN CGO_ENABLED=0 GOOS=linux go build -a -ldflags="-s -w" -installsuffix cgo -o server . && \ +RUN go get -v ./... && \ + CGO_ENABLED=0 GOOS=linux go build -a -ldflags="-s -w" -installsuffix cgo -o server . && \ upx -v --best --ultra-brute --overlay=strip server && \ upx -t server