github.com/eikeon/docker@v1.5.0-rc4/docs/man/docker-tag.1.md (about)

     1  % DOCKER(1) Docker User Manuals
     2  % Docker Community
     3  % JUNE 2014
     4  # NAME
     5  docker-tag - Tag an image into a repository
     6  
     7  # SYNOPSIS
     8  **docker tag**
     9  [**-f**|**--force**[=*false*]]
    10  [**--help**]
    11  IMAGE[:TAG] [REGISTRYHOST/][USERNAME/]NAME[:TAG]
    12  
    13  # DESCRIPTION
    14  This will give a new alias to an image in the repository. This refers to the
    15  entire image name including the optional TAG after the ':'. 
    16  
    17  # "OPTIONS"
    18  **-f**, **--force**=*true*|*false*
    19     When set to true, force the alias. The default is *false*.
    20  
    21  **REGISTRYHOST**
    22     The hostname of the registry if required. This may also include the port
    23  separated by a ':'
    24  
    25  **USERNAME**
    26     The username or other qualifying identifier for the image.
    27  
    28  **NAME**
    29     The image name.
    30  
    31  **TAG**
    32     The tag you are assigning to the image.  Though this is arbitrary it is
    33  recommended to be used for a version to distinguish images with the same name.
    34  Note that here TAG is a part of the overall name or "tag".
    35  
    36  # OPTIONS
    37  **-f**, **--force**=*true*|*false*
    38     Force. The default is *false*.
    39  
    40  # EXAMPLES
    41  
    42  ## Giving an image a new alias
    43  
    44  Here is an example of aliasing an image (e.g., 0e5574283393) as "httpd" and 
    45  tagging it into the "fedora" repository with "version1.0":
    46  
    47      docker tag 0e5574283393 fedora/httpd:version1.0
    48  
    49  ## Tagging an image for a private repository
    50  
    51  To push an image to an private registry and not the central Docker
    52  registry you must tag it with the registry hostname and port (if needed).
    53  
    54      docker tag 0e5574283393 myregistryhost:5000/fedora/httpd:version1.0
    55  
    56  # HISTORY
    57  April 2014, Originally compiled by William Henry (whenry at redhat dot com)
    58  based on docker.com source material and internal work.
    59  June 2014, updated by Sven Dowideit <SvenDowideit@home.org.au>
    60  July 2014, updated by Sven Dowideit <SvenDowideit@home.org.au>