-
Notifications
You must be signed in to change notification settings - Fork 417
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow pipx to use sytem certificates #961
Comments
Adding However, that seems like a hack. Happy to help troubleshoot further. |
I'm having this issue too. I can get around this for standard pip using the pip install pip-system-certs config --trusted-host pypi.org --trusted-host files.pythonhosted.org Unfortunately pipx doesn't seem to respect it. I'd try the above workaround but I'm on MacOS and I can't seem to find where it stores its certs. |
PR welcome to support such custom flags during package installation. |
This can be solved by setting the global cert flag in pip (where ca_certs is the folder containing your custom cert): pip config set global.cert ~/ca_certs or by setting the SSL_CERT_FILE environment variable: export CERT_PATH=/etc/ssl/certs/ZscalerRootCA.pem
export CERT_DIR=/etc/ssl/certs/
export SSL_CERT_FILE=${CERT_PATH}
export SSL_CERT_DIR=${CERT_DIR}
export REQUESTS_CA_BUNDLE=${CERT_PATH} Source: zscaler docs |
While a good solution, isn't it more of a workaround? Shouldn't pipx solve this? At least in my case where pip handled it without any extras. |
I spent 3 hrs today debugging why an app suddently stopped working with SSL Cert Errors. Turns out it was because we migrated fron pip to pipx, and it doesnt use the system certificates... 🤦♂️ |
@gaborbernat Setting the ENV's from the zscaler post above makes this work. Is this something pipx could do without adding another flag? At least on linux the ca-certificates package creates a bundle/certs at This .crt file will have all the commonly know CA certs + whichever custom ones you added to the system |
I am no longer involved in maintaining this project. I moved over to UV tool. |
Describe the bug
pipx install
fails due to corporate network/proxy with self-signed certificate.From the log:
Note that if I create a venv, things work as expected. So the system python/pip handles the (installed) self-signed cert:
I'm using the zipapp (pipx.pyz), version (
1.2.0
)My environment is Ubuntu 22.04 running in WSL on Windows 10.
Python is 3.10.6
How to reproduce
To reproduce I guess you have to be in an environment that has a proxy with a self-signed cert.
Expected behavior
pipx successfully installs package.
cmd_2023-03-29_13.44.16.log
The text was updated successfully, but these errors were encountered: