lessmore/Dockerfile

20 lines
399 B
Docker
Raw Permalink Normal View History

2021-04-02 17:11:12 +03:00
FROM golang:1.16 AS builder
ENV CGO_ENABLED=0
COPY . /build
WORKDIR /build
RUN go build -o /lessmore -v . && strip /lessmore
FROM alpine AS final
COPY --from=builder /lessmore /usr/local/bin/lessmore
COPY --from=builder /build/templates /usr/local/share/lessmore/templates
COPY --from=builder /build/static /usr/local/share/lessmore/static
USER nobody
ENTRYPOINT ["/usr/local/bin/lessmore"]