Docker: add a step to reduce image size and use entrypoint

This commit is contained in:
2026-03-05 14:07:21 +01:00
parent 8cea5b968a
commit 9d2d56a09b

View File

@@ -3,9 +3,12 @@ FROM node:lts AS buildfront
COPY front . COPY front .
RUN npm install && npm run build RUN npm install && npm run build
FROM golang:1.25 FROM golang:1.25 AS build
WORKDIR /src WORKDIR /src
COPY . . COPY . .
COPY --from=buildfront ./dist front/dist COPY --from=buildfront ./dist front/dist
RUN go build -tags=embed RUN go build -tags=embed -o /bin/bibliomane
CMD ["./bibliomane", "-D", "-C", "-n"]
FROM debian:bookworm
COPY --from=build /bin/bibliomane /bin/bibliomane
ENTRYPOINT ["/bin/bibliomane"]