diff --git a/Dockerfile.modelscope b/Dockerfile.modelscope index c032595..ea28f6a 100644 --- a/Dockerfile.modelscope +++ b/Dockerfile.modelscope @@ -17,7 +17,6 @@ RUN sed -i 's|http://deb.debian.org|http://mirrors.aliyun.com|g' /etc/apt/source ca-certificates \ libpq-dev \ chromium \ - ffmpeg \ libreoffice-writer-nogui \ libreoffice-calc-nogui \ libreoffice-impress-nogui \ @@ -37,13 +36,13 @@ ENV PATH="/root/.cargo/bin:$PATH" # 复制requirements文件并安装Python依赖 COPY requirements.txt . -RUN pip install --no-cache-dir --timeout 120 -i https://pypi.tuna.tsinghua.edu.cn/simple/ --trusted-host pypi.tuna.tsinghua.edu.cn -r requirements.txt +RUN pip install --no-cache-dir -i https://mirrors.aliyun.com/pypi/simple/ -r requirements.txt -# 安装 Playwright(跳过浏览器下载,使用系统已安装的 chromium) -ENV PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD=1 -ENV PLAYWRIGHT_CHROMIUM_EXECUTABLE_PATH=/usr/bin/chromium -RUN pip install --no-cache-dir --timeout 120 -i https://pypi.tuna.tsinghua.edu.cn/simple/ --trusted-host pypi.tuna.tsinghua.edu.cn playwright -RUN npm install -g playwright sharp nodemailer dotenv +# 安装 Playwright 并下载 Chromium +RUN pip install --no-cache-dir -i https://mirrors.aliyun.com/pypi/simple/ playwright && \ + playwright install chromium +RUN npm install -g playwright sharp nodemailer dotenv && \ + npx playwright install chromium # 安装modelscope #RUN pip install --no-cache-dir -i https://mirrors.aliyun.com/pypi/simple/ modelscope