瀏覽代碼

fix(docker): 删除 PEP 668 EXTERNALLY-MANAGED 标记,解决 Ubuntu 24.04 系统 Python 无法安装 pip 包的问题

kinglee 2 周之前
父節點
當前提交
c911a73548
共有 1 個文件被更改,包括 3 次插入0 次删除
  1. 3 0
      pack/Dockerfile

+ 3 - 0
pack/Dockerfile

@@ -509,6 +509,9 @@ RUN --mount=type=cache,target=/root/.cache \
     export UV_SYSTEM_PYTHON=1
     export UV_LINK_MODE=copy
 
+    # Remove PEP 668 EXTERNALLY-MANAGED marker to allow system-wide pip installs
+    rm -f /usr/lib/python*/EXTERNALLY-MANAGED
+
     # Build GPUStack
     cd /workspace/gpustack \
         && git config --global --add safe.directory /workspace/gpustack \