monzo-ingestion/Dockerfile
Joshua Coles af0588c5ef
Some checks failed
Rust CI / Build and Test (push) Has been cancelled
Replace the Docker build with the one from toggl-bridge as it's better
2024-08-09 09:57:48 +01:00

15 lines
522 B
Docker

FROM --platform=$BUILDPLATFORM debian:bullseye-slim AS builder
ARG TARGETPLATFORM
WORKDIR /app
COPY . .
RUN case "$TARGETPLATFORM" in \
"linux/amd64") BINARY_PATH="target/release/toggl-bridge" ;; \
"linux/arm64") BINARY_PATH="target/aarch64-unknown-linux-gnu/release/toggl-bridge" ;; \
*) exit 1 ;; \
esac && \
mv "$BINARY_PATH" /usr/local/bin/toggl-bridge
FROM --platform=$TARGETPLATFORM debian:bullseye-slim
COPY --from=builder /usr/local/bin/toggl-bridge /usr/local/bin/
CMD ["toggl-bridge"]