Saturday, April 27, 2024

Docker

 Docker virtualizes Application Layer of an Operating System.

It runs on top of the native Operating System Kernel layer. In this way, Docker images are entirely running in the application space.


Commands

  1. Find Docker images on the local machine: docker images
  2. Find Docker containers running on the local machine: docker ps
  3. Download image version from DockerHub: docker pull nginx:1.23
  4. Download latest image from DockerHub: docker pull nginx
  5. Run image of specific version: docker run nginx:1.23
  6. Run container in the background: docker run -d nginx:1.23
  7. Print container logs to terminal: docker logs <containerid>


No comments:

Post a Comment