Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

docker push error : tag does not exist

Tags:

When pushing a docker image to registry, I got this message :

   docker push   -t   domain.com/repo/tag_docker_name:latest      Error tag name does not exist 

The only way is to create the tag in docker repository via web interface, and then docker push works.

Is there a command line to create docker push ?

like image 205
tensor Avatar asked Apr 14 '18 17:04

tensor


People also ask

Does Docker push push all tags?

Push all tags of an imageUse the -a (or --all-tags ) option to push all tags of a local image. The following example creates multiple tags for an image, and pushes all those tags to Docker Hub.

How do I push an image into Docker Hub?

To push an image to Docker Hub, you must first name your local image using your Docker Hub username and the repository name that you created through Docker Hub on the web. You can add multiple images to a repository by adding a specific :<tag> to them (for example docs/base:testing ).

Which tags does not exist in HTML?

Self-closing tags ( <tag /> ) do not exist in HTML. However, the start tags of SVG and MathML elements that cannot have any child nodes are allowed to be marked as self-closing. In such cases, if an element's start tag is marked as self-closing, the element must not have an end tag.


2 Answers

You need to add a tag to the image, here is the documentation. Use it like this docker tag 0e5574283393 domain.com/repo/tag_docker_name:latest where 0e5574283393 is the image hash

like image 137
David Avatar answered Sep 20 '22 14:09

David


First there is no option -t for docker push command

Second assume that you already have a tagged image said repo/your_image:tag, you should follow the push syntax docker push repo/your_image:tag, docker host should not be included (in your case domain.com) unless you want to push the image to a private repository.

A simple way to check whether the image name existed is to use docker images, which lists all images available on the host, and image name should be the same as displayed in REPOSITORY column.

Follow this link to check docker documentation

like image 30
LarryK Avatar answered Sep 21 '22 14:09

LarryK