PyPi¶
This repository is used for storing python packages. The process of working with one of the twine package publishing tools is described below. To work with other tools, use their official documentation.
Depending on the working environment used, the commands may differ (python/python3, pip/pip3, etc.).
Setup package info (in setup.py
)¶
To publish a package in your namespace, add UID at the beginning of the package name:
Packaging¶
Before publishing the package, you must package it (make sure that you have the latest versions of setuptools and wheel installed):
After completion, two files must be generated in the dist directory:
Uploading¶
To publish the package to the repository, run (make sure that you have the twine module installed):
$ pip install --user --upgrade twine
$ twine upload -u mail -p password --repository-url https://artifactory.$LOC.icdc.io/repository/pypi-hosted/ ./dist/*
Installing¶
To install a previously uploaded package from the repository run:
$ pip install --index-url https://artifactory.$LOC.icdc.io/repository/pypi-hosted/simple UID-example-pkg-name
PyPI Repository access control
Currently, the development of the PyPI repository format is not officially completed. Therefore, any user can upload any package to the repository, but only packages that start with their UID or TEAM_NAME will be available to users for use and management.
Due to modified functionality in the area of access control the CLI tools search function is not available, but the browse and search can still be performed via the Web interface.