pip指定安装源

安装指定的包,并指定安装源

RUN pip install -r requirements.txt -i https://pypi.tuna.tsinghua.edu.cn/simple

requirements.txt内容如下:

ldap3==2.5.1
IPy==1.0
dnspython==1.16.0
simplejson==3.16.0
redis==3.2.1
pymongo==3.7.2
elasticsearch5
Flask==1.0.2
Flask-Script==2.0.6
Flask-Cors==3.0.9
impacket
gunicorn==20.0.0

阿里云:http://mirrors.aliyun.com/pypi/simple/

中国科技大学 https://pypi.mirrors.ustc.edu.cn/simple/

原文地址:https://www.cnblogs.com/dreamer-fish/p/15316859.html