Step 5: Docker
Time: 5 minutes
Purpose: Install Docker for containerized development and deployment
Install Docker
Installation: Follow the official guide at docs.docker.com/get-docker
Platform | Installation Method | Official Documentation |
---|---|---|
macOS | Docker Desktop | docs.docker.com/desktop/mac |
Windows | Docker Desktop | docs.docker.com/desktop/windows |
Linux | Docker Engine | docs.docker.com/engine/install |
Quick Install Commands
# macOS (Homebrew)
brew install --cask docker
# Windows (Chocolatey - PowerShell 7 as Administrator)
choco install docker-desktop -y
# Linux (Ubuntu/Debian) - See official docs for other distributions
curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh get-docker.sh
sudo usermod -aG docker $USER # Add user to docker group
Direct Downloads (GUI Installers)
Docker Desktop:
- macOS: desktop.docker.com/mac
- Windows: desktop.docker.com/win
Linux: Follow distribution-specific instructions at docs.docker.com/engine/install
Start Docker
macOS/Windows
- Launch Docker Desktop from Applications/Start Menu
- Wait for Docker to start (you'll see the Docker icon in your system tray)
- Docker will run automatically on system startup
Linux
# Start Docker service
sudo systemctl start docker
# Enable Docker to start on boot
sudo systemctl enable docker
Verification
# Check Docker version
docker --version
# Check Docker is running
docker info
# Test Docker works
docker run hello-world
Expected output for docker run hello-world
:
Hello from Docker!
This message shows that your installation appears to be working correctly.
...
Configure Docker (Optional but Recommended)
Increase Memory/CPU (macOS/Windows)
- Open Docker Desktop
- Go to Settings → Resources
- Increase Memory to 4GB+ and CPU to 2+ cores
- Click "Apply & Restart"
Configure Docker Daemon (All Platforms)
Create or edit ~/.docker/daemon.json
:
{
"log-driver": "json-file",
"log-opts": {
"max-size": "10m",
"max-file": "3"
}
}
Troubleshooting
Docker Desktop won't start (macOS/Windows)
- Check system requirements (Docker needs virtualization enabled)
- Restart your computer
- Try running Docker Desktop as Administrator (Windows)
- Check for conflicting virtualization software
"Permission denied" errors (Linux)
# Make sure you're in the docker group
groups $USER # Should include 'docker'
# If not, add yourself and restart
sudo usermod -aG docker $USER
# Log out and back in, or restart your session
"Cannot connect to Docker daemon"
- Make sure Docker Desktop is running (macOS/Windows)
- Check Docker service status (Linux):
sudo systemctl status docker
- Try restarting Docker service:
sudo systemctl restart docker
WSL2 issues (Windows)
If using WSL2 backend:
- Make sure WSL2 is properly installed
- Update WSL2 kernel:
wsl --update
- In Docker Desktop settings, ensure "Use WSL2 based engine" is checked
Next Step
Step 6: Artifact Management (Company Required)
Note: The next steps are company-specific tools that are required for all company development work.