Sobes.tech
Junior — Middle

What is the difference between a Docker image and a container?

sobes.tech AI

Answer from AI

A Docker image is a template that contains all the necessary instructions and dependencies to run an application: code, libraries, configurations, etc. The image is static and unchanging.

A container is a running instance of an image, an isolated environment in which the application runs. Containers can be started, stopped, and modified during runtime.

In simpler terms:

  • An image is like a "blueprint" or "template".
  • A container is a "live" process created based on that template.

For example, you create a Docker image with a web server, and then run several containers from this image to handle requests.

What is the difference between a Docker image and a… - sobes.tech