tcc/ActixAPI/Dockerfile

22 lines
717 B
Docker
Raw Normal View History

2024-03-24 19:31:39 -03:00
FROM rust:1.77-buster as builder
WORKDIR /app
COPY . .
RUN cargo build --release
2023-09-24 10:56:01 -03:00
2024-03-24 19:31:39 -03:00
FROM debian:bullseye-slim
2023-10-03 15:31:33 -03:00
WORKDIR /app
2023-09-24 10:56:01 -03:00
2023-11-04 00:41:12 -03:00
RUN apt-get update && apt-get -y install wget && \
2024-01-15 21:03:44 -03:00
wget https://files.ivanch.me/api/public/dl/ch3NV0P8/small-image.png && \
wget https://files.ivanch.me/api/public/dl/jNlXYMLR/big-image.png && \
wget https://files.ivanch.me/api/public/dl/QdKvaeQI/video.mp4 && \
wget https://files.ivanch.me/api/public/dl/YD4vmSsO/nginx.html && \
2024-03-24 19:31:39 -03:00
mkdir -p ./static && \
2023-10-03 15:31:33 -03:00
mv small-image.png ./static && \
mv big-image.png ./static && \
mv video.mp4 ./static && \
2024-03-24 19:31:39 -03:00
mv nginx.html ./static
2023-09-24 10:56:01 -03:00
2024-03-24 19:31:39 -03:00
COPY --from=builder /app/target/release/ActixAPI .
2023-09-24 10:56:01 -03:00
2024-03-24 19:31:39 -03:00
CMD ["./ActixAPI"]