mirror of
https://github.com/d0zingcat/gocryptotrader.git
synced 2026-05-29 23:16:51 +00:00
maintain dockerfile layering and fix docker-compose build (#165)
This commit is contained in:
committed by
Adrian Gallagher
parent
6b575dd925
commit
e3c98b9078
@@ -1,8 +1,9 @@
|
||||
FROM golang:1.10 as build
|
||||
RUN curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
|
||||
WORKDIR /go/src/gocryptotrader
|
||||
WORKDIR /go/src/github.com/thrasher-/gocryptotrader
|
||||
COPY Gopkg.* ./
|
||||
RUN dep ensure -vendor-only
|
||||
COPY . .
|
||||
RUN dep ensure
|
||||
RUN mv -vn config_example.json config.json \
|
||||
&& GOARCH=386 GOOS=linux CGO_ENABLED=0 go install -v \
|
||||
&& mv /go/bin/linux_386 /go/bin/gocryptotrader
|
||||
@@ -10,6 +11,6 @@ RUN mv -vn config_example.json config.json \
|
||||
FROM alpine:latest
|
||||
RUN apk update && apk add --no-cache ca-certificates
|
||||
COPY --from=build /go/bin/gocryptotrader /app/
|
||||
COPY --from=build /go/src/gocryptotrader/config.json /app/
|
||||
COPY --from=build /go/src/github.com/thrasher-/gocryptotrader/config.json /app/
|
||||
EXPOSE 9050
|
||||
CMD ["/app/gocryptotrader"]
|
||||
|
||||
Reference in New Issue
Block a user