2020-02-12 15:50:45 +00:00
|
|
|
FROM golang@sha256:cee6f4b901543e8e3f20da3a4f7caac6ea643fd5a46201c3c2387183a332d989 AS builder
|
|
|
|
RUN apk update && apk add --no-cache git make ca-certificates && update-ca-certificates
|
2020-02-13 15:48:32 +00:00
|
|
|
COPY main.go /go/src/git.martyn.berlin/martyn/karaokards/
|
|
|
|
COPY internal/ /go/src/git.martyn.berlin/martyn/karaokards/internal/
|
2020-02-21 18:07:08 +00:00
|
|
|
COPY Makefile /go/src/git.martyn.berlin/martyn/karaokards/
|
|
|
|
RUN cd /go/src/git.martyn.berlin/martyn/karaokards/; make deps ; make static
|
2020-02-12 15:50:45 +00:00
|
|
|
|
|
|
|
FROM scratch
|
|
|
|
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
|
2020-02-13 15:48:32 +00:00
|
|
|
COPY --from=builder /go/src/git.martyn.berlin/martyn/karaokards /app/
|
2020-02-12 15:50:45 +00:00
|
|
|
COPY strings.json /app/strings.json
|
2020-02-14 14:56:10 +00:00
|
|
|
COPY web/ /app/web/
|
|
|
|
WORKDIR /app
|
2020-02-12 15:50:45 +00:00
|
|
|
CMD ["/app/karaokards"]
|