This project provides a simple solution to manage private Python packages using a GitHub-hosted PyPi index. With secure access through GitHub authentication, it allows for easy installation of both public and private packages while ensuring visibility and control over package vulnerabilities.
This project provides a Github-hosted PyPi index, enabling users to centralize access to all private packages while adhering to PEP 503. It facilitates the seamless installation of packages via pip, similar to how one would install publicly available packages.
To install packages indexed in this repository, execute:
pip install public-hello --extra-index-url https://astariul.github.io/github-hosted-pypi/
This will also automatically install its dependency, mydependency.
To use the package in Python:
from public_hello import hi
print(hi())
To install a specific version of a package:
pip install public-hello==0.1 --extra-index-url https://astariul.github.io/github-hosted-pypi/
Note: Private packages such as private-hello require proper authentication to access:
pip install private-hello --extra-index-url https://astariul.github.io/github-hosted-pypi/
This installation will fail due to access restrictions.
To create your own repository using this template:
Settings tab of your new repository and enable Github Pages.index.html and pkg_template.html files to fit your needs.<user>.github.io/<repo_name>.After setting up your index, register, update, or delete packages with Github Actions:
Actions tab.The project addresses potential supply chain attacks by verifying package authenticity through alerts when installing packages that duplicate names with higher versions in the public index.
Open to contributions, feedback, and suggestions. For any ideas or queries, please create an issue or pull request.
Inspired by this repository, it aims to enhance user experience with cleaner layouts and automated workflows.
No comments yet.
Sign in to be the first to comment.