- Could not fetch URL https://pypi.org/simple/djangorestframework/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/djangorestframework/ (Caused by SSLError("Can't connect to HTTPS URL because the SSL module is not available.")) - skipping
永久性设置,是在用户根目录(~,而非系统根目录 / )下添加配置~/.pip/pip.conf目录添加可信源,如果目录文件不存在,可直接创建。
[root@localhost ~]# cd
[root@localhost ~]# mkdir .pip
[root@localhost ~]# cd .pip
[root@localhost .pip]# vim pip.conf
写入如下内容
[global]
index-url=http://pypi.douban.com/simple
trusted-host = pypi.douban.com
加上trusted-host防止pip报警。