mirror of
https://github.com/status-im/fathom.git
synced 2025-03-01 03:20:27 +00:00
use multi-stage docker build to compile in container too
This commit is contained in:
parent
372394ab44
commit
ef1efd2c98
@ -1,8 +1,11 @@
|
|||||||
FROM alpine:latest
|
FROM golang:latest AS compiler
|
||||||
|
WORKDIR /go/src/github.com/usefathom/fathom
|
||||||
|
ADD . /go/src/github.com/usefathom/fathom
|
||||||
|
RUN go get -u github.com/gobuffalo/packr/... && make build
|
||||||
|
|
||||||
|
FROM alpine:latest
|
||||||
EXPOSE 8080
|
EXPOSE 8080
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
ADD ./fathom /app/fathom
|
COPY --from=compiler /go/src/github.com/usefathom/fathom/fathom .
|
||||||
CMD ["./fathom"]
|
CMD ["./fathom"]
|
||||||
|
|
||||||
RUN apk add --update bash ca-certificates && rm -rf /var/cache/apk/*
|
RUN apk add --update bash ca-certificates && rm -rf /var/cache/apk/*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user