first, I’m new to this forum so please bear with me if this is not the right place to discuss this topic.
I would like to share a tool we developed - micropipenv https://github.com/thoth-station/micropipenv.
The main purpose of it is to parse poetry.lock/Pipfile.lock or requirements.txt and install the dependencies stated. It turned out to be a good solution for us when deploying containerized applications into cluster orchestrators, such as Kubernetes/OpenShift:
- no need to distribute Pipenv or poetry inside container images
- micropipenv saves ~30MiB in the resulting container
- one tool that installs application dependencies from any lock file
- micropipenv can also convert Pipfile.lock/poetry.lock into their requirements.txt counterpart (pip-tools compatible output)
micropipenv does not implement any resolver, it does not manage any virtual environment (as Pipenv/Poetry). It just parses a lock file or requirements.txt file (that should be distributed with the application anyway in a resolved form) and installs dependencies using pip with some additional failover logic for dependencies where the installation order matters.
Hoping it could be helpful for others as well.