tips:pypi

PYPI

create

download
htpasswd -sc htpasswd.txt galileo

update

download
htpasswd -s htpasswd.txt <user2>

Client authentication use keyring and: - ~/.pip/pip.conf for install - ~/.pypirc for publish and eventually for clear password

~/.pip/pip.conf

download
[global]
extra-index-url = http://localhost:8081
                  https://pypi.csgalileo.org
trusted-host = localhost

now it is possible to use install command like “pip install blabla

~/.pypirc

download
[distutils]
index-servers =
    galileo
    localhost

[localhost]
repository = http://localhost:8081
username = galileo
#password = <first-repository password>


[galileo]
repository = https://pypi.csgalileo.org
username = galileo
# not needed if keyring is used
#password = <first-repository password>

now it is possibile publish package like

download
twine upload -r galileo dist/*

twine has keyring utility add galileo user to keyring

keyring set http://localhost:8081 galileo
  • tips/pypi.txt
  • Last modified: 2023/04/13 15:10
  • by sscipioni