-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support referencing base images from a manifest list #1567
Comments
There's something I am still not getting it. For example,
|
Jib doesn't use manifest lists: to do so requires that we request
$ docker manifest inspect openjdk
{
"schemaVersion": 2,
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"manifests": [
{
"mediaType": "application/vnd.docker.distribution.manifest.v2+json",
"size": 2208,
"digest": "sha256:08620da8ca7a66f433de9bf14bdcdd390292436f049a7a407a49eabad67d0827",
"platform": {
"architecture": "amd64",
"os": "linux"
}
},
{
"mediaType": "application/vnd.docker.distribution.manifest.v2+json",
"size": 2207,
"digest": "sha256:c5830875c4e5341dbc70996f33a58f7eed38f9d68d084c2ca183326fd14d14a7",
"platform": {
"architecture": "arm",
"os": "linux",
"variant": "v5"
}
},
{
"mediaType": "application/vnd.docker.distribution.manifest.v2+json",
"size": 2207,
"digest": "sha256:79a149aef2e344ad38924e0999442a62ed93f8cab9eb35c39ae4414899bfccd9",
"platform": {
...
# Inspect manifest for ARM image
$ docker manifest inspect openjdk@sha256:c5830875c4e5341dbc70996f33a58f7eed38f9d68d084c2ca183326fd14d14a7
{
"schemaVersion": 2,
"mediaType": "application/vnd.docker.distribution.manifest.v2+json",
"config": {
"mediaType": "application/vnd.docker.container.image.v1+json",
"size": 5597,
"digest": "sha256:ae097c632fbe620b26d0df6fd32a831d98e90666f3a88feb69ba8011cd235928"
},
"layers": [
{
"mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip",
"size": 44029811,
"digest": "sha256:35963a726ee5d52a496a31b3c1f6accaf90ad61bf0e1e0bd8aad2cf66ab8cdb3"
},
...
]
} And I can confirm that building against |
I know pulling a manifest (not manifest list) by a digest works, but rather, my question was more about the following:
That is, pulling a manifest list by a tag has been working, but pulling the very same manifest list by a digest doesn't work. And I think I now know why. Based on this comment, I guess it is the intention that a digest for a manifest list (e.g., the reference in #1360) won't work in the same way as it does when using a tag (e.g., |
Bumping to P1 as it's actually not that easy to find the right digest for a manifest-list. |
NB: OCI supports a similar concept called an image index. |
Okay started on this: tracking progress here:
|
Newer Jib versions now have an incubating feature to select a base image matching a user-configured platform from a manifest list. For usage, refer to the FAQ "How do I specify a platform in the manifest list (or OCI index) of a base image?". As an incubating feature, there are limitations. For example, pushing a manifest list (in other words, selecting multiple base images) is not supported and being tracked by #2523. Closing. |
Follow-on to #1547 (and #1360), users should be able to identify a platform for base image from a manifest list. Manifest lists are a mechanism for aggregating and serving platform-specific images from a registry. The list specifies manifests with a set of annotations for
os
,architecture
,os.version
,os.features
,variant
(cpu), andfeatures
(cpu).There's a nice article describing use of manifest lists. The Docker CLI support an experimental
--platform
argument for specifying os/arch/variant combinations.A related question is support for creating and pushing manifest lists — including perhaps being able to reference images built by jib within the reactor.
remove/update the FAQ entryThe text was updated successfully, but these errors were encountered: