Files
Modrinth-plus/apps/labrinth/Dockerfile

27 lines
751 B
Docker
Raw Normal View History

2024-10-16 16:12:23 -07:00
FROM rust:1.81.0 as build
ENV PKG_CONFIG_ALLOW_CROSS=1
WORKDIR /usr/src/labrinth
COPY . .
2024-10-16 16:07:24 -07:00
RUN cargo build --release
FROM debian:bookworm-slim
2024-10-18 17:00:36 -07:00
LABEL org.opencontainers.image.source=https://github.com/modrinth/code
LABEL org.opencontainers.image.description="Modrinth API"
LABEL org.opencontainers.image.licenses=AGPL-3.0
RUN apt-get update \
2024-10-16 16:07:24 -07:00
&& apt-get install -y --no-install-recommends ca-certificates openssl \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
RUN update-ca-certificates
COPY --from=build /usr/src/labrinth/target/release/labrinth /labrinth/labrinth
COPY --from=build /usr/src/labrinth/migrations/* /labrinth/migrations/
COPY --from=build /usr/src/labrinth/assets /labrinth/assets
WORKDIR /labrinth
2020-08-28 20:24:43 +02:00
CMD /labrinth/labrinth