Skip to content

Latest commit

 

History

History
59 lines (40 loc) · 2.41 KB

README.md

File metadata and controls

59 lines (40 loc) · 2.41 KB

Docker Workshop - Docker Hub

Sections:

Docker Hub


Think of Docker Hub being to docker what Github is to source control systems for git

Docker Hub is the central repository or "store" for sharing images.

Private Repositories for Docker Hub are also available to store images:

Using Docker Hub


Throughout the workshop we used docker pull SOME_IMAGE and each time we did this we pulled content from docker hub.

  • Browse https://hub.docker.com/ to find other images to download.
  • Browse Docker Store as the new image explorer
  • Each image usually has a Dockerfile showing how that image was built and instructions on using the image.
    • Environment variables to set and more

Adding images to Docker Hub


(You can use AWS, Azure, or other private registries if you want to keep private images)

  1. Create an account on https://hub.docker.com/.

  2. Run docker login in order to login into the hub and push images.

  3. Note the profile picture section has your username as well as My Profile, Logout and more sections.

  4. Tag an image in the form username/imagename:version

    1. Notice I tag my images with jbelmont/someimage:
    2. Remember we tagged an image like this docker tag hello-world jbelmont/hello-world
    3. Note the registry details are in the image name.
    4. This makes it more difficult to move images between repositories or to build automation though
  5. docker push username/imagename:version substituting the details of the image you tagged above.

    1. docker push jbelmont/hello-world we pushed our newly tagged image with this command

Bread Crumb Navigation


Previous Next
Docker Swarm Continuous Integration