Files
skills-publish-packages/.github/steps/5-run-your-image.md
T
2023-11-16 13:14:44 -08:00

1.1 KiB

Step 5: Run your image

Nicely done grabbing your Docker image! ☺️

Let's trying running it.

⌨️ Activity: Run your image

  1. Find your image information by typing docker image ls. screenshot of output from Docker image ls command: lists docker images, REPOSITORY TAG and docker URL
  2. Use the following command to run a container from your image:
    docker run -dp 8080:80 --rm <YOUR_IMAGE_NAME:TAG>
    
  3. Replace YOUR_IMAGE_NAME with your image name under the REPOSITORY column.
  4. Replace TAG with the image tag under the TAG column.
  5. Press Enter.
  6. If everything went well, you will see hash value as output on your screen.
  7. Optionally, you can open localhost:8080 to see the page you just created.
  8. We can't automatically verify this step for you, so please continue on to the next step below!