1.3 : Installation (Windows/Linux/Mac) et vérification

Windows Linuxand Mac: Setting Up the Workshop

Before you can start working with containers, you need to installDocker on your machine. Fortunately,Docker is available on all modern systems: Windows, Mac, and Linux.

Windows

On Windows 10 or 11, the official solution isDocker Desktop.

  1. DownloadDocker Desktop from the official website.
  2. Linux During installation,Docker requires a runtime to run containers. You have two options:
    • Hyper-V: Windows’ native virtualization technology
    • WSL 2 (Windows Subsystem forLinux 2): recommended, lighter, and simpler for most users
  3. Follow the instructions to enable WSL 2 if you haven’t already (Windows offers to install it automatically inDocker Desktop).
  4. Once installation is complete, launchDocker Desktop.
  5. Verify thatDockerit works in PowerShell or CMD:
docker --version

Tip:

For Windows, WSL 2 is generally faster and compatible with all modern features of Docker, while Hyper-V can be useful on older machines or for specific configurations.

It is important to restart your machine ifDocker prompts you to complete the WSL installation.

MAC

On Mac,Docker Desktop works on macOS 11 or later.

  1. DownloadDocker Desktop for Mac from the official website.
  2. Open the file.dmgand drag the iconDockerinto the Applications folder.
  3. LaunchDocker Desktop from your Applications.
  4. Verify the installation in the terminal:
docker --version

Linux

LinuxOn Linux, the installation process varies depending on the distribution. Let’s take Debian/Ubuntu as an example:

sudo apt update
sudo apt install -y docker.io
sudo systemctl start docker
sudo systemctl enable docker
docker --version

To verify thatDocker can be used without sudo (optional):

sudo usermod -aG docker $USER

You’ll need to log out and log back in for the group to take effect.


My practical tip for Windows and Mac

If you’re taking the course on a personal computer running Windows or Mac, the simplest and safest way to get as close as possible to the course environment is to installDocker in a virtual machine.

You can create this virtual machine using a virtualization tool like VirtualBox. This way:

  • You avoid affecting your main system with changes or dependencies specific to Docker.
  • The environment remains isolated, identical to the one used in the course demonstrations.
  • You can easily reset or reproduce your environment if a problem arises.

Even thoughDocker Desktop runs directly on Windows or Mac, this approach provides a more stable and reproducible experience, ideal for learning at your own pace.