How to understand this sentence: docker can realize the function of virtual machine isolating application environment, and the cost is smaller than that of virtual machine, so small means saving money. `

  docker, question

When reading this Docker document:https://www.zhihu.com/questio …

Generally speaking, we can create different virtual machines on the server and place different applications on different virtual machines, but the overhead of virtual machines is relatively high. Docker can realize the function of virtual machine to isolate application environment, and the cost is smaller than that of virtual machine, so small means saving money.

How do you understand this sentence?

What he meant was that in order to achieve a goal, it was necessary to open multiple virtual machines and different services on each virtual machine. Now only one virtual machine needs to be opened, can multiple Docker be opened on this virtual machine to achieve the goal?

Assuming that an application is deployed in an isolated environment (docker container or virtual machine), the number of containers that can be started on a physical machine is definitely much larger than the number of virtual machines that can be created, so it is obvious which is more or less expensive for each application. Of course, the isolation of virtual machines is more thorough or safer than containers.