Upstream has blocked it. A fork over this one little feature is long overdue.
Upstream has blocked it. A fork over this one little feature is long overdue.
There's already a widely available way to specify exactly which repo you'd prefer in the docker client...
`docker pull [repo]/[image]:[tag]`
And that address format works across basically all of the tooling.
Changing the defaults doesn't actually make sense, because there's no guarantee that repo1/secure_image === repo2/secure_image.
Seems like a HUGE security issue to default named public images to a repo where the images may not be provided by the same owner.
Giving people the option to configure a default repository via the daemon.json would alleviate that issue, but I'm not sure if that's really enough to fork.
With these changes, I can imagine “intro to docker” tutorials breaking.
I suspect that’ll be enough to let a fork/competitor gain significant market share.
I doubt it.
It's just not that hard to go fully qualified.
Remember, tags are mutable. `latest` today can be different tomorrow.
And it expands to all other tags. Nothing prevents me from pushing a new 'version' of a container to an existing `v1.0.1` tag.
Tags are not a way of uniquely identifying a container.
The top level image hashes tend to change between repos (because the image name changes in the manifest and is included in the hash).
So you'd have to go through an verify each layer sha.
Good tool for selecting an exact image in a repo, not a replacement for trust at the naming level (it's a bit like the difference between owning a domain and cert pinning with hpkp).
Ex - lots of refs are to "multi-arch" images, Except... there's no such thing as a multi-arch image, the entire identifier is just a reference to a manifest that then points to a list of images (or other manifests) by arch, and the actual resolved artifact is a single entry in that list.
But it means the manifest needs to be able to reference and resolve other names, and that means including... names.
For a more concrete example, just check https://github.com/moby/moby/issues/44144#issuecomment-12578...
Basically - the digests weren't intended to support image verification across repos, and the tool doesn't treat them that way. The digest was intended to allow tighter specification than a tag (precisely because a publisher might push a different image to the same tag later).
One way to get around this is to just not use `latest` at all, and only push docker tags that perfectly mirror the corresponding git branches/tags.
So the source of the image can be decided on pull. Some more on this https://www.redhat.com/en/blog/manage-container-registries
It looks like it's ordered by priority.
unqualified-search-registries = ['registry.fedoraproject.org', 'registry.access.redhat.com', 'registry.centos.org', 'docker.io']
So you get a concatenation of all those registries and transient network failures are going to change the behavior. I'll take a pass on that one.(podman is a docker compatible replacement with a number of other nice features besides being able to configure the registry)
that said, you can configure "registry-mirrors" in /etc/docker/daemon.json although it is not the same thing