Open mjpieters opened 1 month ago
We are attempting to sniff the platform to determine which managed installations are relevant. We might be able to fix that, I'm not quite sure how though.
You probably want one of the images that isn't distroless.
cc @konstin should we set an environment variable in the distroless images for glibc? (or something else?)
We can't reliably sniff the glibc version from inside the container, at least if we want to also provision Python. What about something like -e UV_LIBC="$(/lib/ld-linux.so.2 --version)"
/-e UV_LIBC="$(/lib/ld-musl-x86_64.so.1 --version)"
(is there a platform independent one?) for docker where you pass in the context and we parse our the right libc kind and version?
Note that on MacOS, with Docker Desktop, docker itself runs inside a virtualised linux emulator, and so you can't trivially access /lib/ld-linux.so.2
or /lib/ld-musl-x86_64.so.1
from the host OS, at least not trivially.
Does that mean you want to use the docker uv with a host mac os python, not another linux Python?
docker run --rm -it ghcr.io/astral-sh/uv:latest /bin/sh If this command fails, it means that the image itself may have problems.
That will always fail, and not because our image has problems — the image is distroless and only contains the uv binary.
You probably want one of the images that isn't distroless.
^this
Does that mean you want to use the docker uv with a host mac os python, not another linux Python?
Exactly. But, we'll use uv
locally, instead.
(To be exact: uv
is used to manage venvs inside docker containers, but for certain operations having uv
run locally is just much much nicer, given how fast the tool is).
Given that the documentation suggests that you can use the docker container as a command-line tool I found it very surprising that you can't, in fact, use
uv
in this manner:The
tree
command should not require a Python interpreter (see #8634), but theELF
error here is especially confusing.