mirror of
https://github.com/bloomberg/goldpinger.git
synced 2026-08-23 21:36:25 +00:00
Update the multistage build to use go 1.14 and go modules; Remove dep
Signed-off-by: Sachin Kamboj <skamboj1@bloomberg.net>
This commit is contained in:
+6
-7
@@ -1,15 +1,14 @@
|
||||
FROM golang:1.11-alpine as builder
|
||||
FROM golang:1.14-alpine as builder
|
||||
|
||||
# Install our build tools
|
||||
|
||||
RUN apk add --update git make bash
|
||||
RUN go get -u github.com/golang/dep/cmd/dep
|
||||
|
||||
# Get dependencies
|
||||
|
||||
WORKDIR /go/src/github.com/bloomberg/goldpinger
|
||||
COPY Gopkg.toml Gopkg.lock Makefile ./
|
||||
RUN make vendor
|
||||
WORKDIR /w
|
||||
COPY go.mod go.sum /w/
|
||||
RUN go mod download
|
||||
|
||||
# Build goldpinger
|
||||
|
||||
@@ -19,6 +18,6 @@ RUN make bin/goldpinger
|
||||
# Build the asset container, copy over goldpinger
|
||||
|
||||
FROM scratch
|
||||
COPY --from=builder /go/src/github.com/bloomberg/goldpinger/bin/goldpinger /goldpinger
|
||||
COPY --from=builder /w/bin/goldpinger /goldpinger
|
||||
COPY ./static /static
|
||||
ENTRYPOINT ["/goldpinger", "--static-file-path", "/static"]
|
||||
ENTRYPOINT ["/goldpinger", "--static-file-path", "/static"]
|
||||
|
||||
Reference in New Issue
Block a user