github.com/opiuman/docker@v1.6.0/docs/man/docker-push.1.md (about)

     1  % DOCKER(1) Docker User Manuals
     2  % Docker Community
     3  % JUNE 2014
     4  # NAME
     5  docker-push - Push an image or a repository to a registry
     6  
     7  # SYNOPSIS
     8  **docker push**
     9  [**--help**]
    10  NAME[:TAG] | [REGISTRY_HOST[:REGISTRY_PORT]/]NAME[:TAG]
    11  
    12  # DESCRIPTION
    13  
    14  This command pushes an image or a repository to a registry. If you do not
    15  specify a `REGISTRY_HOST`, the command uses Docker's public registry located at
    16  `registry-1.docker.io` by default. 
    17  
    18  # OPTIONS
    19  **--help**
    20    Print usage statement
    21  
    22  # EXAMPLES
    23  
    24  # Pushing a new image to a registry
    25  
    26  First save the new image by finding the container ID (using **docker ps**)
    27  and then committing it to a new image name:
    28  
    29      # docker commit c16378f943fe rhel-httpd
    30  
    31  Now, push the image to the registry using the image ID. In this example the
    32  registry is on host named `registry-host` and listening on port `5000`. To do
    33  this, tag the image with the host name or IP address, and the port of the
    34  registry:
    35  
    36      # docker tag rhel-httpd registry-host:5000/myadmin/rhel-httpd
    37      # docker push registry-host:5000/myadmin/rhel-httpd
    38  
    39  Check that this worked by running:
    40  
    41      # docker images
    42  
    43  You should see both `rhel-httpd` and `registry-host:5000/myadmin/rhel-httpd`
    44  listed.
    45  
    46  # HISTORY
    47  April 2014, Originally compiled by William Henry (whenry at redhat dot com)
    48  based on docker.com source material and internal work.
    49  June 2014, updated by Sven Dowideit <SvenDowideit@home.org.au>
    50  April 2015, updated by Mary Anthony for v2 <mary@docker.com>
    51