You are viewing a single thread.
View all comments
25 points

Does docker really spin up a VM to run containers?

permalink
report
reply
26 points

Yes, under windows and osx at least.

permalink
report
parent
reply
10 points

Is that still true? I use Linux but my coworker said docker runs natively now on the M1s but maybe he was making it up

permalink
report
parent
reply
9 points

Maybe they just meant that it runs ARM binaries instead of running on Rosetta 2.

permalink
report
parent
reply
9 points

I suspect they meant it runs natively in that it’s an aarch64 binary. It’s still running a VM under the hood because docker is really just a nice frontend to a bunch of Linux kernel features.

permalink
report
parent
reply
3 points

Docker requires the Linux kernel to work.

M1 is just worse arm. Since most people use x86_64 instead of arm, docker had to emulate that architecture and therefore had performance issues. Now you’ve got arm specific images that don’t require that hardware emulation layer, and so work a lot better.

Since that didn’t solve the Linux kernel requirement, it’s still running a VM to provide it.

permalink
report
parent
reply
1 point

Not making it up, but possibly confused. OCI containers are built on Linux-only technologies.

permalink
report
parent
reply
5 points

So that’s why it’s so memory hungry…

permalink
report
parent
reply
2 points

Try limiting it down to 2GB (there is an option in the Docker Desktop app). Before I discovered this option, the VM was normally eating 3-4GB of my memory.

permalink
report
parent
reply
4 points

On macos it does

permalink
report
parent
reply

Programmer Humor

!programmer_humor@programming.dev

Create post

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

  • Keep content in english
  • No advertisements
  • Posts must be related to programming or programmer topics

Community stats

  • 7.2K

    Monthly active users

  • 954

    Posts

  • 37K

    Comments