Skip to main content

Docker Installation

In This Document

Contents

Core Sections

As mentioned in the requirements, you need to install Docker to run this project. This page provides guidance on how to install Docker on different operating systems.

Why Docker?

Docker provides a consistent development environment across all platforms, ensuring that your application runs the same way in development as it does in production.

Install Docker

Install Docker on Ubuntu

Follow these steps to install Docker on Ubuntu:

Step 1: Update your package list
sudo apt update
Step 2: Install prerequisites
sudo apt install apt-transport-https ca-certificates curl software-properties-common
Step 3: Add Docker's official GPG key
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
Step 4: Add the Docker repository
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
Step 5: Update the package database
sudo apt update
Step 6: Install Docker
sudo apt install docker-ce
Step 7: Verify the installation
sudo systemctl status docker
Step 8: Add your user to the docker group
sudo usermod -aG docker ${USER}
Step 9: Apply the new group membership
su - ${USER}
note

You may need to log out and log back in for the group changes to take effect.

For more detailed instructions, visit the Digital Ocean guide on installing Docker on Ubuntu.

Install Docker Compose

Docker Compose is included with Docker Desktop for Mac and Windows. No additional installation is required.

Verify the installation:

Verify Docker Compose installation
docker-compose --version

Post-Installation Steps

After installing Docker, it's a good idea to verify that everything is working correctly:

Test Docker installation
# Run a simple container
docker run hello-world

You should see a message indicating that your installation appears to be working correctly.

Common Issues and Troubleshooting

Docker daemon not running

If you encounter an error like "Cannot connect to the Docker daemon", try starting the Docker service:

# On Linux
sudo systemctl start docker

# On macOS/Windows
# Open Docker Desktop application
Permission denied

If you get a "permission denied" error when running Docker commands:

# Add your user to the docker group
sudo usermod -aG docker ${USER}

# Apply changes (log out and log back in, or run:)
su - ${USER}
WSL 2 installation issues on Windows

If you're having trouble installing WSL 2 on Windows, refer to Microsoft's troubleshooting guide.

Next Steps

Now that you have Docker installed, you can proceed to the Project Setup guide to set up the Planet project.