bangs/Dockerfile
Simon Bruder 03f9ef8574
All checks were successful
continuous-integration/drone/push Build is passing
add evaluator
2019-05-26 21:08:24 +00:00

23 lines
432 B
Docker

FROM golang:alpine as builder
WORKDIR /go/src/git.sbruder.de/simon/bangs/evaluator/
COPY evaluator/evaluator.go .
RUN apk add --no-cache git upx
RUN go get -v \
&& CGO_ENABLED=0 go build -v -ldflags="-s -w" \
&& upx --ultra-brute evaluator
FROM scratch
COPY --from=builder /go/src/git.sbruder.de/simon/bangs/evaluator/evaluator /evaluator
copy bangs.json /bangs.json
USER 1000
ENTRYPOINT ["/evaluator"]
EXPOSE 8081