From 07518a1f8f3d3e24074852ac64af6d92948fbf6c Mon Sep 17 00:00:00 2001 From: Lysann Tranvouez Date: Sat, 3 Jan 2026 22:42:40 +0000 Subject: [PATCH] update base image, smaller image type (alpine) --- Dockerfile | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index f26d3a9..617be8a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,10 +1,19 @@ -FROM python:3 +FROM python:3.13.11-alpine3.23 AS builder -WORKDIR /usr/src/app +RUN apk add --no-cache gcc g++ musl-dev rust cargo patchelf COPY requirements.txt ./ RUN pip install --no-cache-dir -r requirements.txt + + +FROM python:3.13.11-alpine3.23 + +COPY --from=builder /usr/local/lib/python3.13/site-packages /usr/local/lib/python3.13/site-packages +RUN apk add --no-cache libstdc++ + +WORKDIR /usr/src/app + COPY . . -CMD [ "python", "-u", "./main.py" ] \ No newline at end of file +CMD [ "python", "-u", "./main.py" ]