DEV Community

Cover image for How to Install Docker on Windows / Mac / Linux
haXarubiX
haXarubiX

Posted on

How to Install Docker on Windows / Mac / Linux

Step-by-Step Docker Installation and Juice Shop Setup (Updated)

Part 1: Installing Docker

1. Docker Installation on Windows and macOS

Docker Desktop makes it incredibly easy to set up Docker on both Windows and macOS. Here’s a quick guide to get you started.

Steps for both Windows and macOS:

  1. Download Docker Desktop:

    • Visit the Docker Desktop website and click “Download for Windows” or “Download for Mac,” depending on your operating system.
  2. Install Docker Desktop:

    • On Windows, simply run the installer .exe file and follow the on-screen instructions.
    • On macOS, open the downloaded .dmg file and drag Docker to your Applications folder.
  3. Launch Docker Desktop:

    • After installation, launch Docker Desktop.
    • Docker Desktop will guide you through the initial setup, and within a few clicks, Docker will be up and running.
  4. Verify Docker Installation:

    • Open PowerShell (Windows) or Terminal (macOS) and type: ```bash

    docker --version

   - You should see the installed version of Docker printed in the terminal.

That’s it! Docker is now installed and ready for use. You don’t need to worry about additional steps since Docker Desktop handles everything, including setting up Docker Compose.

##### **2. Docker Installation on Debian-based Linux (Ubuntu/Kali)**

For Linux users (particularly Debian-based systems like Ubuntu or Kali), installing Docker is also straightforward.

1. **Update Your System:**
   Open your terminal and run the following to ensure your system is up to date:
   ```bash


   sudo apt update
   sudo apt upgrade


Enter fullscreen mode Exit fullscreen mode
  1. Install Docker: Install Docker using the following command: ```bash

sudo apt install docker.io


3. **Install Docker Compose:**
   Since Docker Compose is often used alongside Docker, install it as well:
   ```bash


   sudo apt install docker-compose


Enter fullscreen mode Exit fullscreen mode
  1. Start and Enable Docker: Enable Docker to start at boot and launch it right away: ```bash

sudo systemctl enable docker
sudo systemctl start docker


5. **Verify Installation:**
   Run the following command to check if Docker is installed correctly:
   ```bash


   docker --version


Enter fullscreen mode Exit fullscreen mode

That's it for Linux! Docker and Docker Compose are now installed and ready for use.

Top comments (0)