Skip to main content

Installing Docker

  1. Open Terminal
    • Find the “Terminal” app and click it.
  2. Run the Easy Install Command
    • In Terminal, type or paste this whole line and press Enter:
      wget -qO- https://get.docker.com/ | sh
    • This downloads a small script and runs it. It will install Docker for you.
  3. Wait for It to Finish
    • The script will show text as it downloads and sets up Docker.
    • When the text stops, Docker is installed.
  4. Check Docker Works
    • Still in Terminal, type:
      sudo docker run hello-world
    • Press Enter. Docker will download a tiny test program and run it.
    • If you see “Hello from Docker!”, it means Docker is ready.
  5. Let You Use Docker Without “sudo” (Optional)
    • By default, you need to type sudo before every Docker command. If you want to skip typing sudo, do this:
      1. Type:
        sudo usermod -aG docker $USER

        Press Enter.
      2. Close Terminal and log out of your Ubuntu account. Then log back in.
      3. Now you can run Docker commands without sudo. For example:
        docker run hello-world

That’s it! Docker is now installed on your Ubuntu 22.04 in just one simple step.