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
docker push should allow multiple tags to be pushed #7336
Comments
+1 We tag each container with output from |
I'm in the same case as @tuukkamustonen , getting unnecessarily slow push because of "double tag" in CI. |
+1 I want to push my image with all tags on it in 1 go please |
👍 Same here! We'd like to tag our images with |
+1. We build our images automatically with every commit, so tagging them with both branch name and sha1 works great. |
👍 , definitely |
👍 |
1 similar comment
👍 |
👍 |
2 similar comments
👍 |
👍 |
I'm going to have to bake a birthday cake for this issue soon... almost a year and no love from maintainers :( |
PR's are welcome. |
Unfortunately I got burned really badly on my last PR - spent months trying to get it through only to be rejected, and still no fix 6 months after that. so I'm not willing to make the same investment again :/ |
+1 |
IMO this is a terrible idea and should be avoided at all costs. |
@lox I'd be interested in learning why you think this is a terrible idea. I don't see why something like |
👍 |
👍 |
👍 |
USER POLL The best way to get notified of updates is to use the Subscribe button on this page. Please don't use "+1" or "I have this too" comments on issues. We automatically The people listed below have upvoted this issue by leaving a +1 comment: @amok |
Maybe after 13 months with no word from devs people might think showing their interest in such a feature might get some recognition? Many feature requests for docker seem to go totally ignored; not even so much as a "we've thought about this and made it low priority" from someone on the project. And then the first 'official' response is from a joke account pointing out that people want a feature and are being ignored? Thanks. |
@justin8 see #15624 (comment). I'm quoting :
There is work to do before doing this, and it's kinda a design decision to make. Pushing multiple image is still possible using a for loop in a bash script (or in the api consumer) — this is nice to have but I think it's definitely not a blocker though.. So yeah, I think it's low priority for now. |
Hrm, could several of the +1's have been to my comment that it shouldn't be fixed though? It probably throws into question the entire methodology of @GordonTheTurtle's user poll. |
@vdemeester that's a comment on an entirely different issue. Should people be expected to read all the comments on all 954 open issues? Or perhaps all 7,000 issues and 8,800 merge requests? Thanks for the info though. |
@justin8 note that it's a comment on a pull-request referencing this issue (and appears just on top of the @GordonTheTurtle message even), so people subscribing the issue and that have comment, have been notified of this PR. But yeah, it doesn't cost much to put a comment here too 😉. |
I think the intention of this ticket was to offer a possible solution to the underlying issue which is that docker much recheck every layer multiple times. Issue #12489 better describes what the problem is with the lack of this. Let's close this one and move the discussion to #12489. I'm in favor of pushing this back until later as it isn't as important as others and a workaround does exist (at the great expense of build and deploy times) but only if we could address some critical bugs that have been open for more than year, some, 2 years with, similarly to this issue, little to no attention from developers. The most frustrating thing about the comment from @stevvooe on your PR is that we're almost at 2.0 and an image reference syntax has not yet been locked down. It just seems like a fundamental decision that should have been made long ago. The following critical issues must get fixed snarky comments aside. If you run docker in production you have 100% chance of hitting at least one of these. So if we could fix these instead of this one, that's fine by me. The following important bugs and requests have had ample meaningful discussion but little or no meaningful attention from devs in about a year: I'm starting to understand why the community might be getting frustrated.... |
@mlehner616 I agree that #12489 appropriately addresses the root cause and discussion should be moved their. For this particular issue, checking layer existence is simply not the primary bottleneck. The proper optimization to address this issue is to make the As an aside, we are working on the reference package to address the image reference issue in a consistent, type-safe and uniform manner. This will enable a number of features, such as proper remote configuration. More aptly, proper types and data structures will reduce odd behavior and defects. Unfortunately, because of the high number of stakeholders, this process is slow and painstaking. It would be great if we could get your help on the enumerated issues. The number of contributors working on maintenance is small and the core team is heavily overworked. While these issues seem simple on face value, many require a large amount of time to analyze, reproduce, debug and characterize. A well-done, clear reproduction can do wonders in moving them forward. |
As the original submitter of this ticket, I can confirm that really what it is complaining about is "Pushing and pulling images in a tag-heavy workflow, especially across a WAN, is glacial". Our London team has basically decided that they hate us at this point over this issue and related ones... I never intended to prescribe a particular fix, we just want to not have Docker be the single bottleneck in our entire workflow. The introduction of v2 which even slowed down some operations, as well as introducing new areas of instability (I've had to report three separate issues against it already) has only burned yet more of our "user happiness buffer" with Docker... I'm sympathetic to the "number of developers working on this is low, and number of user requests is high" -- but somehow Docker finds time to implement endless streams of complicated features (An entire software defined networking stack? A new differential Tar format?) while simple usability problems that affect every one of our developers every day go without even a peep from maintainers. |
I just set up a CircleCI pipeline with Docker integration, and I'm having this problem. My pipeline builds a docker image, tags it with $CIRCLE_SHA1, and then pushes the image to our Docker repo. Ideally, I'd like to do a single docker push command, but to update the image tagged as latest, and create the new CIRCLE_SHA1 tag, I'm finding I need to push twice. Each push is about 3-4 minutes, so this is a drag. Suggestions welcome! |
Actually, the second push only takes 3s, so this isn't a big deal for me. |
@stevenschlansker Well said. The biggest gripe I had with the implementation of features issue was the addition of Windows support. Great feature, but thought it was completely unjustified given the critical issues facing the Linux platform as it stands. Docker maintainers can't expect to make decisions like that without blowback from the community especially when people do actually spend time on PRs to have them rejected because it doesn't align with the vision. Community members in the end feel betrayed and move on to other things. Anyway: |
@mlehner616 I'm using a private repo hosted on dockerhub. I don't know if it's registry 1.0 or 2.0--it's whatever dockerhub uses. :) |
@stevenschlansker @mlehner616 I know this can be frustrating but there are a number of factors to take into account when making road map decisions or when accepting PRs. This ticket isn't really the venue for discussing these matters. If you would like to more constructively voice your concerns, I would suggest making this point on the mailing list or via IRC. |
+1, re-tagging every version of the image to push into the registry is time consuming, something like
|
I'm bumping up against this now; a significant portion of one of my app builds will be spent doing layer checks for tag pushes. Don't we have Merkle trees now? I thought this would have allowed efficient layer checking/transfer. |
really what should happen (according to https://docs.docker.com/registry/spec/api/#pushing-an-image-manifest) is docker should push the image manifest, then for each error upload the relevant layers, then upload the manifest. |
ping @stevvooe @aaronlehmann can we get an official view on this ticket? |
@graingert Introducing this syntax will not make push faster. Remember that push is implemented in a daemon, not the cli, so this implementation will result in the same number of HTTP requests to the daemon as it would be in multiple commands. There are a number of optimizations on the table that address the concerns in this issue. Specifically, we are not leveraging cache information between push calls, even though the daemon can maintain this state quite easily. It would be great to get some help to get push working as fast as possible before extending command syntax. We'd really like to reserve extended
We can't have both due the similarities between image names and remote names, which might be a url. We may be able to add multi-tag push once remotes is figured out. In the meantime, we would appreciate help from the community in rooting out the actual performance problems in push without introducing more CLI functionality. |
Great, can you close this issue? |
May be push will not be faster, but command will be clear. Especially in cases we make tag and always move forward |
@Hubbitus I am not sure that you read my comment in full. |
I noticed an issue with the same topic in the I'm going to close this issue in favor of that one, since it's a cli topic. Please don't interpret this as dismissing the feature request - I'm only trying to make sure it's tracked in a single issue in the right place. |
Currently
docker push
can either push all layers and tags, or a single tag. In the case where you build multiple layers or tag the same layer with multiple names, pushing each tag must check that every layer is in the registry (even if they are the same) which can dramatically slow down a tag-heavy workflow.The text was updated successfully, but these errors were encountered: