mirror of
https://github.com/foomo/contentserver.git
synced 2025-10-16 12:25:44 +00:00
Dockerfile build cleanup
This commit is contained in:
parent
422fcf95b6
commit
f75f3a09ae
@ -5,13 +5,10 @@ FROM golang:1.14-alpine AS build-env
|
|||||||
|
|
||||||
WORKDIR /src
|
WORKDIR /src
|
||||||
|
|
||||||
COPY ./go.mod ./go.sum ./
|
|
||||||
RUN go mod download && go mod vendor
|
|
||||||
|
|
||||||
# Import the code from the context.
|
|
||||||
COPY ./ ./
|
COPY ./ ./
|
||||||
|
|
||||||
RUN GOARCH=amd64 GOOS=linux CGO_ENABLED=0 go build -o /contentserver
|
RUN go mod download && go mod vendor
|
||||||
|
RUN GOARCH=amd64 GOOS=linux CGO_ENABLED=0 go build -trimpath -o /contentserver
|
||||||
|
|
||||||
##############################
|
##############################
|
||||||
###### STAGE: PACKAGE ######
|
###### STAGE: PACKAGE ######
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user