polycule-connect/Dockerfile
Melora Hugues 4c3a0c648e
All checks were successful
continuous-integration/drone/push Build is passing
Fix dockerfile and add compose
2023-10-19 18:33:46 +02:00

19 lines
598 B
Docker

FROM --platform=$TARGETPLATFORM golang:1.20 AS builder
ARG TARGETPLATFORM
ARG BUILDPLATFORM
WORKDIR /go/src/git.faercol.me/polyculeconnect
COPY polyculeconnect ./
RUN CGO_ENABLED=0 make build
# Replace with from scratch later on
FROM --platform=$TARGETPLATFORM alpine:latest
WORKDIR /root
COPY --from=builder go/src/git.faercol.me/polyculeconnect/build/polyculeconnect ./
ADD polyculeconnect/robots.txt /root/
ADD polyculeconnect/static /root/static/
ADD polyculeconnect/templates /root/templates/
VOLUME [ "/config" ]
ENTRYPOINT [ "./polyculeconnect" ]
CMD [ "-config", "/config/config.json" ]