Docker push without tags
See original GitHub issueNote
The command docker push
from Docker task 2.0 throws an exception if you do not provide Tag.
Background:
I have two separate build pipelines. First is a pure build with docker save
into artifacts.
The second use the created image with docker load
.
The image is tagged with latest
and $(Build.BuildId)
.
I now simply want to run docker push
without any tags to push all local tags (docker supports that).
If I let the field Tags empty the task failed.
Required Information
Included in the log.
Task logs
2020-05-18T16:44:30.5353665Z ##[section]Starting: push
2020-05-18T16:44:30.5360507Z ==============================================================================
2020-05-18T16:44:30.5360849Z Task : Docker
2020-05-18T16:44:30.5361161Z Description : Build or push Docker images, login or logout, or run a Docker command
2020-05-18T16:44:30.5361475Z Version : 2.169.1
2020-05-18T16:44:30.5362166Z Author : Microsoft Corporation
2020-05-18T16:44:30.5362445Z Help : https://aka.ms/azpipes-docker-tsg
2020-05-18T16:44:30.5362903Z ==============================================================================
2020-05-18T16:44:30.7488711Z [command]/opt/hostedtoolcache/docker-stable/19.3.8/x64/docker images
2020-05-18T16:44:30.7584470Z ##[error]Unhandled: Cannot read property 'split' of null
2020-05-18T16:44:30.7872719Z REPOSITORY TAG IMAGE ID CREATED SIZE
2020-05-18T16:44:30.7873530Z ***/xxx 4297 4627e14f87ac About an hour ago 231MB
2020-05-18T16:44:30.7874337Z ***/xxx latest 4627e14f87ac About an hour ago 231MB
2020-05-18T16:44:30.7875070Z jekyll/builder latest 63f4270653bf 2 weeks ago 668MB
2020-05-18T16:44:30.7876109Z node 12-alpine 7a48db49edbf 2 weeks ago 88.7MB
2020-05-18T16:44:30.7876850Z node 12 9dd56f7e705f 2 weeks ago 916MB
2020-05-18T16:44:30.7877656Z node 10-alpine a07f309c9753 3 weeks ago 83.8MB
2020-05-18T16:44:30.7878214Z alpine 3.9 78a2ce922f86 3 weeks ago 5.55MB
2020-05-18T16:44:30.7878760Z alpine 3.10 be4e4bea2c2e 3 weeks ago 5.58MB
2020-05-18T16:44:30.7879312Z node 10 a02c9f46f94a 3 weeks ago 912MB
2020-05-18T16:44:30.7880096Z buildpack-deps stretch b45c882f0d36 3 weeks ago 835MB
2020-05-18T16:44:30.7880676Z debian 9 bd753a4a335e 3 weeks ago 101MB
2020-05-18T16:44:30.7881466Z debian 8 c6e91fa21856 3 weeks ago 129MB
2020-05-18T16:44:30.7882294Z alpine 3.8 c8bccc0af957 3 months ago 4.41MB
2020-05-18T16:44:30.7883021Z ubuntu 14.04 6e4f1fe62ff1 5 months ago 197MB
2020-05-18T16:44:30.7883617Z alpine 3.7 6d1ef012b567 14 months ago 4.21MB
2020-05-18T16:44:30.7884557Z mcr.microsoft.com/azure-pipelines/node8-typescript latest 9a948d360778 19 months ago 595MB
2020-05-18T16:44:30.7965631Z ##[section]Finishing: push
Error logs
[Insert error from the logs here for a quick overview]
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (1 by maintainers)
Top Results From Across the Web
do I need to manually tag "latest" when pushing to docker ...
NOTE: pushing without a tag (ie: docker push foo/bar ) pushes all the local images marked with repo foo/bar. If one of those...
Read more >Tag without pull/push? - Docker Community Forums
I run create and upload my :latest on one server, and if they pass the tag logic is on another server. That second...
Read more >Understanding Docker image tags and publishing ... - ITNEXT
1 tags refer to the same image (hence same layers), no new layers are pushed for the latest tag. When we push a...
Read more >The misunderstood Docker tag: latest | by Marc Campbell
Because I want to push this image to Docker Hub, I'm going to build, tag and version my image. sudo docker build -t...
Read more >Prevent tags from being overwritten - Docker Documentation
By default, users with access to push to a repository, can push the same tag multiple times to the same repository. As an...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Sorry for the trouble. The issue has been hotfixed on all the affected rings. The task should be working fine for everyone now.
@Ettores88 I’ve opened a PR that could be used as a fix for this issue: https://github.com/microsoft/azure-pipelines-tasks/pull/12955. As for an ETA that’ll be up to the good folks at Microsoft.
So far I’ve only had to work around two broken pipelines, but there could be up to 8 more for me; agreed that this is frustrating.