Files
badger/Dockerfile
T
2020-08-10 17:01:12 +10:00

31 lines
427 B
Docker

FROM golang:1.14-alpine AS build
RUN apk add --no-cache git openssh
ENV GOOS=linux
ENV GOARCH=amd64
WORKDIR /app
COPY . .
RUN go mod download
RUN go build -o badger main.go
FROM alpine:3.11
RUN apk add --no-cache bash
RUN adduser -D -u 1000 junv
WORKDIR /home/junv
USER junv
COPY --from=build /app/fonts ./fonts
COPY --from=build /app/badger badger
COPY --from=build /app/static ./static
CMD ["/home/junv/badger"]