mirror of
https://github.com/jessfraz/dockerfiles.git
synced 2024-11-23 11:31:49 +01:00
make mop/Dockerfile use build stages (#426)
This commit is contained in:
parent
2d259b95ed
commit
8d1c962183
|
@ -5,7 +5,7 @@
|
|||
# --name mop \
|
||||
# r.j3ss.co/mop
|
||||
#
|
||||
FROM alpine:latest
|
||||
FROM alpine:latest as builder
|
||||
|
||||
RUN apk --no-cache add \
|
||||
ca-certificates
|
||||
|
@ -24,9 +24,8 @@ RUN buildDeps=' \
|
|||
set -x \
|
||||
&& apk --no-cache add $buildDeps \
|
||||
&& go get github.com/mop-tracker/mop/cmd/mop \
|
||||
&& mv /go/bin/mop /usr/bin/mop \
|
||||
&& apk del $buildDeps \
|
||||
&& rm -rf /go \
|
||||
&& echo "Build complete."
|
||||
|
||||
FROM alpine:latest
|
||||
COPY --from=builder /go/bin/mop /usr/bin/mop
|
||||
ENTRYPOINT [ "mop" ]
|
||||
|
|
Loading…
Reference in New Issue
Block a user