DELAPARRA
Index
Color
NL
Category: Docker

tag-and-push

Explained by Updated

What is tag-and-push?

tag-and-push: The standard publish flow: tag a local image with the target registry path, then push it there. Tag-and-push is the standard way to publish a Docker image. First give the local image a name that includes the registry address, then push it: docker tag myapp:1.0 registry.example.com/team/myapp:1.0, followed by docker push registry.example.com/team/myapp:1.0.

Definition source Coders Lingo, CC BY 4.0

Frequently asked questions about tag-and-push

How is tag-and-push used in practice?

The registry path in the name tells Docker where to upload. Without it, Docker assumes Docker Hub.

What should you keep in mind with tag-and-push?

In practice, your CI pipeline does this after every successful build, often with the commit hash as the tag. You can also tag the image directly during the build with docker build -t registry.example.com/team/myapp:abc123 ., which saves a step. Log in to the registry first with docker login, and in CI use a token with push rights only for the repositories it needs.

What does an example of tag-and-push look like?

docker tag myapp:1.0 ghcr.io/acme/myapp:1.0 docker push ghcr.io/acme/myapp:1.0

At a glance

CategoryDocker
Explained by
Updated

More Docker terms

All terms starting with T

Skills

Download all skills (zip)

Manuals

Related services

Need any help?

Stuck on one of these in your own project? Tell me what you are working on and I will tell you how I would approach it.