-
Notifications
You must be signed in to change notification settings - Fork 0
Publish images for different builds of python #6
Comments
Depends on renovatebot/docker-python#18 |
this might be a little nasty if you want to provide full compatibility of any python version/potery version pair. some folks might decide for whatever reason to do poetry:1.0.1 and python 3.8.2. this will lead to a cartesian explosion of base images. I was thinking, maybe it makes sense to download a python version dynamically in the image using something like pyenv? the downside being that it will add much more runtime |
For Bundler we prebuild Ruby images and dynamically install Bundler as it adds only a few seconds. Most package managers are unfortunately much longer to install. |
An idea I'd like to explore is if we can have a base image with multiple versions of Python installed using pyenv and then dynamically pick the right one at runtime before running |
Relevant: python-poetry/poetry#305 Concerning:
|
This is a guide to What I'm hoping for is:
|
I'd say the only potential caveat, if you are also supporting all patch versions, is that the image might be humongous to pull |
Yeah, we need to check that and then evaluate against how much data we'd ultimately pull anyway if we have a matrix of python X poetry versions and users spread out across many. On a fairly fast mac on a fairly fast internet connection,
It's slow but manageable, if we have no other solution. |
any update on this? we unfortunately can't update to python 3.8 yet because of renovate |
@itajaja I wasn't able to get a definite answer on the feasibility of running multiple python versions etc. Any research/assistance you can do on that would be appreciated. e.g. could we:
|
hey @rarkins happy to help. I don't know the internals of renovate much, and these choices seem more like implementation details than user facing, but I might be misunderstanding. |
This only slightly related to Renovate's internals, so don't worry there. Something we'd like to avoid is needing to build/publish a cross-matrix of every supported python version X every poetry version. So instead I'm trying to work out if we can have one published image per Poetry version that runs on a base that includes all python versions and switches them using pyenv. What I don't know for example is:
|
no, no need. so you can first change the python version with pyenv and then run poetry |
Thanks! So then the Dockerfile would look something like this? (pseudocode):
And then at runtime, we'd do something like this (again.. pseudocode):
|
yeah! except instead of "install poetry into python 3.8", the best way to install poetry is globally with vendorized deps. see https://python-poetry.org/docs/#installation. 3.[6-8] seems like a fair range to me, but it's up to you what versions you want to support :) |
I'm wondering if this helps us? python-poetry/poetry#1477 Is it "reasonable" that we expect users to follow this approach, or is it too limiting? |
I'm going to "bat signal" @sdispater here, hope he may have the time to look. @sdispater here's what we want to do:
It's acceptable if we need to tell users "if you want this to work in all scenarios then configure your poetry like X" but ideally it would "just work" for anyone using Poetry 1.x. |
I think what that would allow you to do is to avoid introspecting the pytproject.py file to look for the python version. it's doable without it, but it's less work for you if that gets in |
This should work with latest version of renovate |
We need to support multiple builds of python, e.g. at least
3.7
and3.8
but probably also down to full precision like3.7.5
.We also need to work out a naming convention, e.g.
renovate/poetry:1.0.0-python3.7
andrenovate/poetry:1.0.0-python3.8
.The text was updated successfully, but these errors were encountered: