The Hotel Hero

Notes by a Sysadmin


Cluster | Philosophy | Stack

Docker Hub - Create image

April 11, 2021 | Cluster

Create an image on Docker Hub, there are other ways of creating images. But, the following is based on a "Dockerfile".

"cd" into the directory of your Dockerfile, which is the formula for your image, and execute the following line:

docker build -t <your_username>/my-private-repo .

After this operation you have created a local image/container. Before publishing anything public, you would probably test and se if the container is working properly:

docker run <your_username>/my-private-repo

Login to Docker Hub:

docker login --username=your_username

After that you can publish the container:

docker push <your_username>/my-private-repo


About

I'm a Sysadmin, network manager and cyber security entusiast. The main purpose of this public "notebook" is for referencing repetitive tasks, but it might as well come in handy to others. Windows can not be supported! But all other OS compliant with the POSIX-standard can (with minor adjustments) apply the configs on the site. It is Mac OSX, RHEL and all the Fedora based distros and Debian based (several 100's of OS's), all the BSD distros, Solaris, AIX and HP-UX.

Links