Using pip behind a proxy with CNTLM

前端 未结 30 2281
囚心锁ツ
囚心锁ツ 2020-11-22 11:00

I am trying to use pip behind a proxy at work.

One of the answers from this post suggested using CNTLM. I installed and configured it per this other post, but runnin

30条回答
  •  遇见更好的自我
    2020-11-22 11:33

    You can continue to use pip over HTTPS by adding your corporation's root certificate to the cacert.pem file in your site-packages/pip folder. Then configure pip to use your proxy by adding the following lines to ~/pip/pip.conf (or ~\pip\pip.ini if you're on Windows):

    [global]
    proxy = [user:passwd@]proxy.server:port
    

    That's it. No need to use third party packages or give up HTTPS (of course, your network admin can still see what you're doing).

提交回复
热议问题