做本地房产网站,国外做伞的品牌网站,大连大连建设工程信息网站,免费的素材库视频无水印一、问题现象
构建镜像时#xff0c;使用pip命令打包报错#xff1a; 二、问题根因
因国内无法访问pip的配置文件中的仓库地址
三、解决办法
这个办法同样适用于#xff1a;物理机#xff0c;这个地址是阿里云的
pip config set global.index-url http://mirrors.aliy… 一、问题现象
构建镜像时使用pip命令打包报错 二、问题根因
因国内无法访问pip的配置文件中的仓库地址
三、解决办法
这个办法同样适用于物理机这个地址是阿里云的
pip config set global.index-url http://mirrors.aliyun.com/pypi/simple/
pip config set install.trusted-host mirrors.aliyun.com
FROM python:3.8COPY . /app
RUN pip config set global.index-url http://mirrors.aliyun.com/pypi/simple/
RUN pip config set install.trusted-host mirrors.aliyun.com
WORKDIR /appRUN pip install flaskCMD [python, app.py]四、其他仓库地址
阿里云http://mirrors.aliyun.com/pypi/simple/中国科学技术大学https://pypi.mirrors.ustc.edu.cn/simple/清华大学https://pypi.tuna.tsinghua.edu.cn/simple/豆瓣https://pypi.douban.com/simple/