docker1 Min Read

Docker Push: How to push your docker image to your organization in hub.docker.com

Gorav Singal

March 07, 2018

TL;DR

Tag your image as orgname/imagename:tag instead of username/imagename, then docker push. You must have write access to the organization on Docker Hub.

Docker Push: How to push your docker image to your organization in hub.docker.com

Introduction

I have seen the repeated solution on docker help pages which helps to push your image to your username. Example: ``` First build the image docker build -t .

Tag the image, by seeing its image id, from docker images command docker tag 04d7cc352e96 /<my_image_name>:

Finally, push your image docker push /<my_image_name> </my_image_name></my_image_name></my_image_name>


<h3>Problem</h3>
With above approach, the image will be pushed in path: /<USERNAME>/<my_image_name>

<h3>Example:</h3>
If my username is: goravsingal, and my_image_name=php-apache-mongo

The image will not be published in organization's space. Rather in user's space.

<h2>Solution</h2>

First build the image docker build -t <my_image_name> .

Tag the image, by seeing its image id, from docker images command docker tag 04d7cc352e96 <organization_name>/<my_image_name>:

Finally, push your image docker push <organization_name>/<my_image_name> </my_image_name></organization_name></my_image_name></organization_name></my_image_name>


<h3>Example:</h3>
My org name is: gyanbyte, my_image_name is php-apache-mongo

Build Image docker build -t php-apache-mongo .

Tag image docker tag 04d7cc352e96 gyanbyte/php-apache-mongo:latest

Push in organization docker push gyanbyte/php-apache-mongo


Finally, my path becomes:<a href="https://hub.docker.com/r/gyanbyte/php-apache-mongo/">https://hub.docker.com/r/gyanbyte/php-apache-mongo/</a>

Bingo!
Share

Related Posts

Docker image for Drupal 7, and Php extension MongoDB installed.

Docker image for Drupal 7, and Php extension MongoDB installed.

You have drupal 7 image from docker hub, and want to connect tomongo db via php…

Drupal Helpful codes for database queries

Drupal Helpful codes for database queries

Being a drupal user from last around 5 years, I used to know small codes for…

How to connect Php docker container with Mongo DB docker container

How to connect Php docker container with Mongo DB docker container

Goto your command terminal. Type: This will expose port: 27017 by default. You…

How to Copy Local Docker Image to Another Host Without Repository and Load

How to Copy Local Docker Image to Another Host Without Repository and Load

Introduction Consider a scenario where you are building a docker image on your…

How to connect to a running mysql service on host from a docker container on same host

How to connect to a running mysql service on host from a docker container on same host

Introduction I have a host running mysql (not on a container). I have to run an…

Docker: unauthorized: incorrect username or password.

Docker: unauthorized: incorrect username or password.

While running docker commands with some images, I started getting error: The…

Latest Posts

AI Video Generation in 2025 — Models, Costs, and How to Build a Cost-Effective Pipeline

AI Video Generation in 2025 — Models, Costs, and How to Build a Cost-Effective Pipeline

AI video generation went from “cool demo” to “usable in production” in 2024-202…

AI Models in 2025 — Cost, Capabilities, and Which One to Use

AI Models in 2025 — Cost, Capabilities, and Which One to Use

Choosing the right AI model is one of the most impactful decisions you’ll make…

AI Image Generation in 2025 — Models, Costs, and How to Optimize Spend

AI Image Generation in 2025 — Models, Costs, and How to Optimize Spend

Generating one image with AI costs between $0.002 and $0.12. That might sound…

AI Coding Assistants in 2025 — Every Tool Compared, and Which One to Actually Use

AI Coding Assistants in 2025 — Every Tool Compared, and Which One to Actually Use

Two years ago, AI coding meant one thing: GitHub Copilot autocompleting your…

AI Agents Demystified — It's Just Automation With a Better Brain

AI Agents Demystified — It's Just Automation With a Better Brain

Let’s cut through the noise. If you read Twitter or LinkedIn, you’d think “AI…

Supply Chain Security — Protecting Your Software Pipeline

Supply Chain Security — Protecting Your Software Pipeline

In 2024, a single malicious contributor nearly compromised every Linux system on…