feat: remove useless file

This commit is contained in:
2025-04-03 13:50:12 +08:00
parent f03fc66c1e
commit dd86253162
10 changed files with 44 additions and 268 deletions

View File

@@ -1,10 +1,24 @@
FROM git.mamahaha.work/sangge/tpre:base
COPY src /app
COPY requirements.txt /app/requirements.txt
FROM python:3.13-slim AS base
WORKDIR /app
COPY ./pyproject.toml /app/
COPY lib/* /usr/local/lib/
RUN ldconfig && \
pip install -i https://git.mamahaha.work/api/packages/sangge/pypi/simple/ ecc-rs==0.1.2 --no-cache-dir
RUN pip install -r requirements.txt -i https://pypi.tuna.tsinghua.edu.cn/simple
# Development stage
FROM base AS dev
RUN pip install -e ".[dev]" -i https://pypi.tuna.tsinghua.edu.cn/simple --no-cache-dir
# Test stage
FROM base AS test
COPY ./tests /app/tests
RUN pip install -e ".[test]" -i https://pypi.tuna.tsinghua.edu.cn/simple --no-cache-dir
ENTRYPOINT ["pytest", "/app/tests"]
CMD ["-xvs"]
# Deployment stage
FROM base AS deploy
WORKDIR /app
COPY --from=base /usr/local/lib/* /usr/local/lib/
COPY src /app
RUN ldconfig