Skip to content
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

Accept full semver in tag (add build metadata support with + symbol) #4877

Closed
Murazaki opened this issue Feb 15, 2024 · 1 comment
Closed

Comments

@Murazaki
Copy link

Murazaki commented Feb 15, 2024

Description

A prior decision has been taken to not accept the + symbol on tag names. The documentation states it here :

After the image name, the optional TAG is a custom, human-readable manifest identifier that's typically a specific version or variant of an image. The tag must be valid ASCII and can contain lowercase and uppercase letters, digits, underscores, periods, and hyphens. It can't start with a period or hyphen and must be no longer than 128 characters. If you don't specify a tag, the command uses latest by default.

https://docs.docker.com/engine/reference/commandline/image_tag/

This goes directly against the semver notation, since semver accepts the + symbol as an indicator of build metadata.
The reasoning for this is that builds should not differ.

The issue is this is highly opinionated and there's several cases where this does not work:

  • When CI rebuilds an image, it may break it, then it is very hard to come back to previous for users apart for searching for the image SHA, which is less readable and meaningful for them
  • Build metadata is used for patching, but also forking an app. In this case we lose highly valuable information on the version of the image

The request is simple (even though accepting it and implementing it might be very complex depending on the pipelines affected) : accept + in tag names to fix semver compliance and give back this possibility to users

This issue is linked to docker/metadata-action#385 and docker/metadata-action#384

@thaJeztah
Copy link
Member

Thanks for opening. Unfortunately, this is not something that can be implemented in the CLI (or daemon, which does the actual handling for this) currently without breaking compatibility. Implementing this would need the change to be accepted and implemented in registries, other runtimes (such as containerd, and others), and possibly defined in some of the (OCI) specifications.

Some prior discussions can be found in (among others) below, and may contain further details;

I'll close this ticket in because of the above, but feel free to continue the conversation.

@thaJeztah thaJeztah closed this as not planned Won't fix, can't repro, duplicate, stale Feb 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants