I have a private PyPI repository. Is there any way to store credentials in pip.conf
similar to .pypirc
?
What I mean. Currently in .pypirc
you can have such configuration:
[distutils]
index-servers = custom
[custom]
repository: https://pypi.example.com
username: johndoe
password: changeme
From what I've found that you can put in pip.conf
:
[global]
index = https://username:[email protected]/pypi
index-url = https://username:[email protected]/simple
cert = /etc/ssl/certs/ca-certificates.crt
But here I see two problems:
- For each url you'll need each time to specify the same username and password.
- Username and password become visible in the logs, cause they are part of the url.
Is there any way to store username and password outside of url?
pip install -q package-name
and if you still wanted the full verbose logs somewhere you could add the--log
option as well to point to a file – Valetudinary