I've searched around and can't find a real answer to this. If I create a docker git repo and set up autobuild to my dockerhub account, it will build with a single tag (i.e. latest, or 1.0 or foo) but I can't find any way to add a tag afterwards as you can via command line with a locally built docker image. Pulling down the image and then retagging doesn't work as the autobuild repos are read-only outside of the webui.
Being able to manually add a tag to an existing build would satisfy me for now, but being able to script in something to grab the correct tag version would be the best solution.
docker build -t image_name:tag_name . otherwise it will give latest tag to you image automatically. Save this answer.
Docker tags are just an alias for an image ID. The tag's name must be an ASCII character string and may include lowercase and uppercase letters, digits, underscores, periods, and dashes. In addition, the tag names must not begin with a period or a dash, and they can only contain 128 characters.
The docker build command builds Docker images from a Dockerfile and a “context”. A build's context is the set of files located in the specified PATH or URL .
Use 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.
You can do this through the UI somewhat indirectly:
Name
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With