BM: Baca dalam Bahasa Melayu
World D0: Start Here
Containers vs virtual machines
You will learn: how a container (a room) differs from a virtual machine (a whole house).
Checked with Docker Engine 29 on 31 Oct 2026
The problem
Ali tests his app in five virtual computers. His laptop crawls like a tortoise. Each one is a whole computer inside his computer. Is there a lighter way?
Pick one answer.
Watch
Tap each point on the timeline.
A virtual machine (VM): A whole house: a full computer with its own operating system, running inside your computer. (VM) is a whole house. A container is one room in a house. Tap each one to compare.
Watch
Your laptop~
- No open hatches
Lunchboxes (containers)
- No containers yet
Frozen packs (images)
- alpine:3.221 layers · 12.9MB
- nginx:1.30-alpine8 layers · 93.5MB
0 containers (0 running), 2 images, 0 lockers.
The room has its own files: Alpine inside, Ubuntu outside. But both show the same kernel: The heart of the operating system. It runs every program. Containers share the laptop's kernel.. The kernel is the house power. It runs every program, in every room.
Try it
House or room? Sort each fact.
Drag a card into a box. Or tap the card, then tap the box.
Try it
Start a room yourself. Type docker run --rm alpine:3.22 echo hi. It says hi, and --rm cleans the room away.
Your laptop~
- No open hatches
Lunchboxes (containers)
- No containers yet
Frozen packs (images)
- alpine:3.221 layers · 12.9MB
- nginx:1.30-alpine8 layers · 93.5MB
0 containers (0 running), 2 images, 0 lockers.
Hint
Copy it exactly:docker run --rm alpine:3.22 echo hi.Predict
Linux containers need a Linux kernel. Your laptop is a Mac. What does Docker Desktop do?
Pick one answer.
Check
Pick the right tool. Is each plan a good idea?
Swipe right for good, left for needs work. Or use the buttons.
Use containers to ship a small web app
You did it!
You can now explain how a container differs from a virtual machine.
Go deeper (optional)
A VM has stronger walls, because each house has its own kernel. Rooms are lighter, but they share one kernel. So many clouds run containers inside VMs: rooms inside houses.
Real rep (optional): once Docker is installed, run docker run --rm alpine:3.22 uname -a and uname -a. Same kernel? On a Mac or Windows, you see the small Linux VM’s kernel.
Bahasa Melayu
Ali uji aplikasinya dalam lima komputer maya. Laptopnya jadi lembap macam kura-kura. Setiap satu ialah komputer penuh di dalam komputernya. Ada cara lebih ringan?
Virtual machine (mesin maya, VM) ialah sebuah rumah penuh. Container ialah sebuah bilik dalam rumah. Tekan setiap satu untuk bandingkan.
Bilik ada fail sendiri: Alpine di dalam, Ubuntu di luar. Tapi kedua-duanya tunjuk kernel yang sama. Kernel ialah elektrik rumah. Ia jalankan setiap program, di setiap bilik.
Rumah atau bilik? Susun setiap fakta.
Buka bilik sendiri. Taip docker run --rm alpine:3.22 echo hi. Ia kata hi, dan --rm kemas bilik itu.
docker run --rm alpine:3.22 echo hi.Container Linux perlukan kernel Linux. Laptop anda Mac. Apa Docker Desktop buat?
Pilih alat yang betul. Setiap rancangan ini idea yang bagus?
Kini anda boleh terangkan beza container dengan virtual machine.
You finished this before. Practice is always welcome!
Official docs: What is a container? · Docker architecture
You've learned for 25 minutes. A short break helps your brain.
Sprint done! Great focus. Stretch for a minute?