⚙️ Docker Installation

Docker Installation: Docker Desktop on Windows/Mac is like an automatic-transmission rental car: it bundles the engine, CLI, Compose, and a GUI so you can drive immediately.

Docker Desktop on Windows/Mac is like an automatic-transmission rental car: it bundles the engine, CLI, Compose, and a GUI so you can drive immediately. Installing the Docker Engine directly on Linux is the manual-transmission version — lighter, faster, no extra layer. So why does Linux skip the GUI wrapper that Windows/Mac need? Because Linux containers run natively on a Linux kernel, while Windows/Mac need a lightweight VM underneath that Docker Desktop quietly manages for you — similar to how a JVM runs natively on Linux servers but needs extra runtime scaffolding in some embedded Windows/Mac setups. The QA risk: your CI pipeline almost always runs the lean Linux Engine, so a container that behaves fine on your Mac's Docker Desktop can still surprise you in the real CI environment — always verify on the actual pipeline, not just locally.

Install Docker Desktop on Windows

Open PowerShell as Administrator and run: wsl --install. This installs WSL 2 which Docker Desktop uses as its backend. Restart your computer after this.

Go to docker.com/products/docker-desktop → Download for Windows. Choose the installer for your architecture (AMD64 for most PCs, ARM64 for Surface Pro X).

Double-click Docker Desktop Installer.exe. Check "Use WSL 2 instead of Hyper-V" (recommended). Click OK and wait for installation.

Launch Docker Desktop from Start menu. Wait for the whale icon 🐳 to appear in system tray and show "Docker Desktop is running".

Verify installation. Expected output: "Docker version 24.x.x, build xxxxx"

Run a test container. Docker downloads the hello-world image and runs it. You should see "Hello from Docker!" — installation successful!

Install Docker on Linux (Ubuntu/Debian)

Install prerequisites for adding Docker's GPG key and repository.

Add Docker's official GPG key for secure package verification.

Add the official Docker repository to apt sources.

Install Docker Engine, CLI, containerd runtime, and Compose plugin.

Add your user to the docker group so you can run Docker without sudo. Log out and back in for this to take effect.

Installation steps

  1. Enable WSL 2 (Windows Subsystem for Linux) — Open PowerShell as Administrator and run: wsl --install. This installs WSL 2 which Docker Desktop uses as its backend. Restart your computer after this.
  2. Download Docker Desktop — Go to docker.com/products/docker-desktop → Download for Windows. Choose the installer for your architecture (AMD64 for most PCs, ARM64 for Surface Pro X).
  3. Run the installer — Double-click Docker Desktop Installer.exe. Check "Use WSL 2 instead of Hyper-V" (recommended). Click OK and wait for installation.
  4. Start Docker Desktop — Launch Docker Desktop from Start menu. Wait for the whale icon 🐳 to appear in system tray and show "Docker Desktop is running".
  5. docker --version — Verify installation. Expected output: "Docker version 24.x.x, build xxxxx"
  6. docker run hello-world — Run a test container. Docker downloads the hello-world image and runs it. You should see "Hello from Docker!" — installation successful!