Back to Developer Roadmap

Container Vs Vm

src/data/question-groups/devops/content/container-vs-vm.md

4.0757 B
Original Source

A container is a runtime instance of a container image (which is a lightweight, executable package that includes everything needed to run your code). It is the execution environment that runs the application or service defined by the container image.

When a container is started, it becomes an isolated process on the host machine with its own filesystem, network interfaces, and other resources. Containers share the host operating system's kernel, making them more efficient and quicker to start than virtual machines.

A virtual machine (VM), on the other hand, is an emulation of a physical computer. Each VM runs a full operating system and has virtualized hardware, which makes them more resource-intensive and slower to start compared to containers.