优化Dockerfile,移除不必要的sources.list复制步骤,简化pip安装命令
Some checks failed
Deploy VitePress site to Pages / build (push) Failing after 1m2s
Docker Image Build / build (push) Failing after 1m29s

This commit is contained in:
远野千束 2024-11-16 02:24:47 +08:00
parent b022a364e3
commit d0619f1fe8

View File

@ -2,15 +2,13 @@ FROM swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/library/python:3.10-slim
ENV TZ Asia/Shanghai
COPY docker/sources.list /etc/apt/sources.list
RUN apt-get update && apt-get install -y git
WORKDIR /liteyukibot
COPY . /liteyukibot
RUN pip install --no-cache-dir -r requirements.txt -i https://pypi.tuna.tsinghua.edu.cn/simple
RUN pip install --no-cache-dir -r requirements.txt
RUN apt-get install -y libnss3 libnspr4 libdbus-1-3 libatk1.0-0 libatk-bridge2.0-0 libcups2 libdrm2 libatspi2.0-0 libxcomposite1 libxdamage1 libxfixes3 libxrandr2 libgbm1 libxkbcommon0 libasound2