21 lines
381 B
Docker
21 lines
381 B
Docker
FROM rust:alpine as builder
|
|
|
|
WORKDIR /app
|
|
|
|
COPY . .
|
|
|
|
RUN apk add musl-dev
|
|
|
|
RUN rm .env # force build from prepared sqlx db info
|
|
RUN cargo build --release
|
|
|
|
|
|
FROM alpine:latest
|
|
|
|
LABEL org.opencontainers.image.source https://git.idlestate.org/azdle/zero-to-axum
|
|
|
|
COPY --from=builder /app/target/release/zero-to-axum /usr/local/bin/zero-to-axum
|
|
|
|
COPY conf/ conf/
|
|
|
|
CMD ["zero-to-axum"]
|