2022-01-13 13:51:02 +01:00
|
|
|
FROM chewingbever/vlang:latest AS builder
|
2022-01-09 09:29:11 +01:00
|
|
|
|
2022-01-13 13:51:02 +01:00
|
|
|
WORKDIR /app
|
2022-01-09 09:29:11 +01:00
|
|
|
|
2022-01-13 13:51:02 +01:00
|
|
|
# Copy over source code & build production binary
|
|
|
|
COPY src ./src
|
|
|
|
COPY Makefile ./
|
2022-01-15 10:31:11 +01:00
|
|
|
RUN LDFLAGS='-lz -lbz2 -llzma -lexpat -lzstd -llz4 -static' \
|
|
|
|
make prod
|
2022-01-09 09:29:11 +01:00
|
|
|
|
|
|
|
|
2022-01-13 13:51:02 +01:00
|
|
|
FROM alpine:3.15
|
2022-01-09 09:29:11 +01:00
|
|
|
|
|
|
|
ENV REPO_DIR=/data
|
|
|
|
|
2022-01-13 13:51:02 +01:00
|
|
|
COPY --from=builder /app/pvieter /usr/local/bin/vieter
|
2022-01-09 09:29:11 +01:00
|
|
|
|
|
|
|
ENTRYPOINT [ "/usr/local/bin/vieter" ]
|