Replies: 1 comment
|
This proposal was based on several offline discussions between @aicam @tanishqgandhi1908 and myself, motivated a real use case of Alpha Fold 3. This proposal includes 1) how to build and maintain an image; and 2) how to use an image for a CU. The first task is what tools such as DockerHub do, so we should avoid inventing the wheels. So I believe we should focus on 2). We can just let a user specify a URL to a DockerHub image when creating a CU, without considering how it's created. The following are my corresponding thoughts on those questions:
|
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Summary
A runtime image is the image a computing unit runs, built from a Dockerfile the user owns.
A computing unit started from one runs that image instead of the deployment's default, so a
workflow can use interpreters, system packages and compiled libraries the default image does
not have.
We have a working prototype and would like opinions before it goes any further — especially
on the questions at the end.
This is the same problem area as #7475, approached from the computing unit rather than the
operator.
The problem
Today a user's only way to add a dependency is a Python virtual environment: a list of pip
specs installed into a venv on the computing-unit image's own interpreter. Three common needs
fall outside that definition, and no amount of effort within the mechanism reaches them:
venvis built from the image's interpreterFROMa different basehmmer,ffmpeg, a driver)apt-get installas root, at build timepip install <spec>RUNyou likeA shell on a running pod does not close the gap either. That shell is the unprivileged
texerauser, soapt installfails, and anything it did install would live in thecontainer's writable layer and vanish on the next restart.
The case that forced it: AlphaFold 3
AlphaFold 3 is a sharp example because it
fails a venv in all three ways at once — it needs Python ≥ 3.12 (the engine's is 3.10),
it is not on PyPI and compiles a C++ extension, and it calls
jackhmmer/nhmmer,which are executables, not Python packages.
This is not a hypothetical dependency. It is the shape of most scientific tooling our users
bring, and each row above is a hard stop rather than an inconvenience.
The prototype
Runtime Images in the sidebar → New runtime image → the editor opens pre-filled with
the computing-unit image's own Dockerfile, so the starting point is what already exists rather
than a blank file. Saving starts a build; Logs is readable during it and after. When
creating a computing unit, the runtime image is picked from a dropdown — only
READYonesappear.
Four decisions worth commenting on:
arbitrary user-supplied instructions, and a privileged builder would make the cluster's
isolation depend on the Dockerfile being well behaved.
:n+1rather than overwriting:n, so a computing unit already running an earlier build is untouched.row learns its outcome when someone lists or opens it — no background threads, no leader
election.
selection.
It runs
AlphaFold 3's data pipeline, on minikube, 2 CPU / 4 GiB, no GPU — AF3 3.0.5 built from
source, calling the real
jackhmmerthroughalphafold3.data.tools.jackhmmer, on Python3.12.14, from an engine whose own interpreter is 3.10:
Flipping the UDF back to the default Python environment fails the identical workflow with
No module named 'alphafold3', which is the point — the selection is load-bearing, and whatit selects is something no venv could have built.
(Structure prediction is out of scope here: no GPU, no model parameters, no 630 GB databases.
This is the dependency problem, not an AF3 port.)
Known limits of the prototype
runtimes treat the Service CIDR as insecure.
USER texeraruns asroot in the pod, because the pod spec pins no
securityContextof its own.old tags are kept.
Questions
Per-unit is much cheaper to build and reason about, but one workflow then cannot mix two
incompatible dependency sets. Is that limit acceptable, or is per-operator the real target?
reference) instead of authoring a Dockerfile we build? That skips the builder entirely, at
the cost of any control over what is inside.
on the cluster. Admins only, an allowlist, or every user with quotas?
common "just add a pip package" case, and they select per-UDF rather than per-unit.
like datasets and workflows, or published to a curated library?
All reactions