From a911bc9fad0b148e59c60130f1d87b0d0ef6306c Mon Sep 17 00:00:00 2001 From: infinitycat Date: Mon, 18 Aug 2025 18:31:07 +0800 Subject: [PATCH] test: test Dockfile --- Dockerfile | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index be76277c..d6553dbc 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,10 @@ FROM python:3.13.5-slim-bookworm COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/ +EXPOSE 8000 + +# 编译器 +RUN RUN apt-get update && apt-get install -y build-essential && rm -rf /var/lib/apt/lists/* +RUN uv pip install --system --upgrade pip Cython py-cpuinfo setuptools # 工作目录 WORKDIR /MaiMBot @@ -10,23 +15,15 @@ COPY requirements.txt . #COPY maim_message /maim_message COPY MaiMBot-LPMM /MaiMBot-LPMM -# 编译器 -RUN apt-get update && apt-get install -y build-essential - # lpmm编译安装 RUN cd /MaiMBot-LPMM && uv pip install --system -r requirements.txt -RUN uv pip install --system Cython py-cpuinfo setuptools RUN cd /MaiMBot-LPMM/lib/quick_algo && python build_lib.py --cleanup --cythonize --install - # 安装依赖 -RUN uv pip install --system --upgrade pip #RUN uv pip install --system -e /maim_message RUN uv pip install --system -r requirements.txt # 复制项目代码 COPY . . -EXPOSE 8000 - -ENTRYPOINT [ "python","bot.py" ] \ No newline at end of file +ENTRYPOINT [ "python","bot.py" ]