Преглед на файлове

build: 更新依赖项并优化Dockerfile配置

- 移除不再需要的pysilk依赖
- 添加torch 2.8.0的安装命令到Dockerfile
- 配置hatch构建系统的wheel打包目标
DengPeng преди 2 седмици
родител
ревизия
c37f7524a0
променени са 2 файла, в които са добавени 6 реда и са изтрити 2 реда
  1. 2 0
      Dockerfile.backend
  2. 4 2
      pyproject.toml

+ 2 - 0
Dockerfile.backend

@@ -32,6 +32,8 @@ COPY main.py ./
 
 RUN pip install .
 
+RUN pip install --no-cache-dir --break-system-packages torch==2.8.0 --index-url https://pypi.tuna.tsinghua.edu.cn/simple
+
 RUN mkdir -p /opt/maxkb-app/model/base /opt/maxkb-app/tmp /opt/maxkb-app/logs
 
 COPY start.sh /opt/maxkb-app/start.sh

+ 4 - 2
pyproject.toml

@@ -57,7 +57,6 @@ dependencies = [
     "pymupdf==1.26.3",
     "pypdf==6.10.2",
     "pydub==0.25.1",
-    "pysilk==0.0.1",
     "gunicorn==23.0.0",
     "python-daemon==3.1.2",
     "websockets==15.0.1",
@@ -88,4 +87,7 @@ torch = [
 
 [build-system]
 requires = ["hatchling"]
-build-backend = "hatchling.build"
+build-backend = "hatchling.build"
+
+[tool.hatch.build.targets.wheel]
+packages = ["apps"]