Dockerfile 539 B

123456789101112131415161718192021222324252627
  1. # ---------- BUILD STAGE ----------
  2. FROM python:3.14-alpine AS builder
  3. RUN apk add --no-cache build-base mariadb-connector-c-dev
  4. WORKDIR /build
  5. COPY requirements.txt .
  6. RUN pip install --prefix=/install -r requirements.txt
  7. # ---------- RUNTIME STAGE ----------
  8. FROM python:3.14-alpine
  9. RUN apk add mariadb-connector-c
  10. COPY --from=builder /install /usr/local
  11. WORKDIR /opt/MyAnimeBot
  12. COPY . .
  13. RUN chown -R 0:0 /opt/MyAnimeBot && chmod -R g+rw /opt/MyAnimeBot
  14. EXPOSE 15200
  15. CMD ["python", "myanimebot.py"]