问题描述
我在Windows上使用Anaconda 2.7,并且我的互联网连接使用代理.
I'm using Anaconda 2.7 on windows, and my internet connection uses a proxy.
以前,当使用python 2.7(不是Anaconda)时,我安装了这样的软件包:
Previously, when using python 2.7 (Not Anaconda), I installed package like this:
pip install {packagename} --proxy proxy-us.bla.com:123
是否可以通过代理参数运行conda
?在conda help
中没有看到它.
Is there a way to run conda
with proxy argument? didn't see it in conda help
.
谢谢
推荐答案
您可以通过将conda添加到.condarc
中来配置具有conda的代理,例如
You can configure a proxy with conda by adding it to the .condarc
, like
proxy_servers:
http: http://user:[email protected]:8080
https: https://user:[email protected]:8080
或设置HTTP_PROXY
和HTTPS_PROXY
环境变量.请注意,根据您的情况,您需要将该方案添加到代理网址中,例如 https://proxy-us.bla.com:123 .
or set the HTTP_PROXY
and HTTPS_PROXY
environment variables. Note that in your case you need to add the scheme to the proxy url, like https://proxy-us.bla.com:123.
请参见 http://conda.pydata. org/docs/config.html#configure-conda-for-use-behind-a-proxy-server .
这篇关于使用代理运行conda的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!