Skip to main content
AI / Machine Learning

Docker & Containers for AI Development

9 Modules
Chapter 9: Resources & Next Steps100%

Resources & Next Steps

Official Documentation

These are the definitive references. Bookmark them -- you'll return to them often.

Docker

ResourceURLWhat it covers
Docker Documentationdocs.docker.comComplete reference for Docker Engine, CLI, Compose
Dockerfile Referencedocs.docker.com/reference/dockerfile/Every Dockerfile instruction explained
Docker Compose Referencedocs.docker.com/compose/Compose file format, CLI commands, networking
Docker Hubhub.docker.comBrowse and search for official and community images
Docker Desktopdocs.docker.com/desktop/Installation, settings, troubleshooting

Dev Containers

ResourceURLWhat it covers
Dev Containers Specificationcontainers.devThe open specification for development containers
Dev Container Featurescontainers.dev/featuresBrowse installable features
Dev Container Templatescontainers.dev/templatesReady-made configurations for common stacks
VS Code Dev Containers Docscode.visualstudio.com/docs/devcontainers/containersVS Code-specific setup and usage
devcontainer.json Referencecontainers.dev/implementors/json_reference/Every configuration option explained

NVIDIA Container Toolkit

ResourceURLWhat it covers
Installation Guidedocs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/install-guide.htmlSetting up GPU access for containers
Docker Integrationdocs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/docker-specialized.htmlDocker-specific GPU configuration

Useful AI Docker Images

These are well-maintained, production-quality images you can use immediately.

Language Models

ImagePurposeExample
ollama/ollamaRun LLMs locally (Llama, Mistral, Gemma, etc.)docker run -d -p 11434:11434 ollama/ollama
vllm/vllm-openaiHigh-throughput LLM serving with OpenAI-compatible APIdocker run --gpus all vllm/vllm-openai --model meta-llama/Llama-3.2-3B-Instruct
ghcr.io/huggingface/text-generation-inferenceHugging Face model servingGPU required, see HF docs for setup

Chat Interfaces

ImagePurposeExample
ghcr.io/open-webui/open-webuiFeature-rich chat UI for Ollama and OpenAI-compatible APIsdocker run -d -p 3000:8080 ghcr.io/open-webui/open-webui:main

Vector Databases

ImagePurposeExample
chromadb/chromaLightweight embedding databasedocker run -d -p 8000:8000 chromadb/chroma
qdrant/qdrantProduction-grade vector searchdocker run -d -p 6333:6333 qdrant/qdrant
semitechnologies/weaviateAI-native vector databaseSee Weaviate docs for Compose setup

Development Environments

ImagePurposeExample
jupyter/scipy-notebookJupyter with scientific Python stackdocker run -p 8888:8888 jupyter/scipy-notebook
jupyter/tensorflow-notebookJupyter with TensorFlowdocker run -p 8888:8888 jupyter/tensorflow-notebook
mcr.microsoft.com/devcontainers/pythonMicrosoft Dev Container base (Python)Used in .devcontainer/devcontainer.json
mcr.microsoft.com/devcontainers/universalDev Container with multiple languagesLarger image but very comprehensive

Utilities

ImagePurposeExample
redis:7In-memory cache and message brokerdocker run -d -p 6379:6379 redis:7
postgres:16Relational database with pgvector extensiondocker run -d -p 5432:5432 -e POSTGRES_PASSWORD=pass postgres:16
nginx:alpineReverse proxy and static file serverdocker run -d -p 80:80 nginx:alpine

Recommended Reading

Books

  • Docker Deep Dive by Nigel Poulton -- the most accessible and thorough introduction to Docker. Updated regularly. Start here if you want one book.
  • Docker in Action (Manning) -- more hands-on, with practical examples throughout.
  • Building Containerized Applications (O'Reilly) -- covers modern patterns for multi-container architectures.

Articles and Guides

Videos

  • Docker in 100 Seconds (Fireship) -- brilliant quick overview if you want a recap
  • Docker Tutorial for Beginners (TechWorld with Nana) -- comprehensive free course on YouTube
  • VS Code Dev Containers Tutorial (VS Code official channel) -- step-by-step walkthrough

Cheat Sheet

Essential Commands

# Images
docker pull <image>              # Download an image
docker build -t <tag> .          # Build from Dockerfile
docker images                    # List local images
docker rmi <image>               # Remove an image

# Containers
docker run <image>               # Create and start
docker run -d <image>            # Run in background
docker run -it <image> bash      # Interactive shell
docker ps                        # List running
docker ps -a                     # List all
docker stop <name>               # Stop
docker rm <name>                 # Remove
docker logs <name>               # View logs
docker exec -it <name> <cmd>     # Run command in running container

# Volumes
docker volume create <name>      # Create
docker volume ls                 # List
docker volume rm <name>          # Remove
docker volume prune              # Remove unused

# Networks
docker network create <name>     # Create
docker network ls                # List
docker network rm <name>         # Remove

# Compose
docker compose up -d             # Start all services
docker compose down              # Stop and remove
docker compose ps                # List services
docker compose logs -f           # Follow logs
docker compose build             # Rebuild images

# Cleanup
docker system prune              # Remove unused data
docker system prune -a           # Remove everything unused (reclaim disk)

Dockerfile Template

FROM python:3.11-slim

# System dependencies
RUN apt-get update && \
    apt-get install -y --no-install-recommends <packages> && \
    rm -rf /var/lib/apt/lists/*

# Non-root user
RUN useradd --create-home appuser

WORKDIR /app

# Python dependencies (cached layer)
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt

# Application code
COPY . .

USER appuser

EXPOSE 8000

CMD ["python", "app.py"]

Compose Template

services:
  app:
    build: .
    ports:
      - "8000:8000"
    volumes:
      - app-data:/app/data
    environment:
      - ENV_VAR=value
    depends_on:
      - db
    restart: unless-stopped

  db:
    image: postgres:16
    volumes:
      - db-data:/var/lib/postgresql/data
    environment:
      POSTGRES_PASSWORD: ${DB_PASSWORD}

volumes:
  app-data:
  db-data:

devcontainer.json Template

{
  "name": "My Project",
  "image": "mcr.microsoft.com/devcontainers/python:3.11",
  "features": {
    "ghcr.io/devcontainers/features/node:1": {"version": "20"}
  },
  "customizations": {
    "vscode": {
      "extensions": ["ms-python.python"],
      "settings": {"editor.formatOnSave": true}
    }
  },
  "postCreateCommand": "pip install -r requirements.txt",
  "forwardPorts": [8000],
  "remoteUser": "vscode"
}

Next Steps in the DreamLab Workshop Series

Now that you understand containerisation, you're well prepared for:

  • Phase 4: Claude Code -- uses containerised development environments
  • Phase 5: AI Agents & Orchestration -- multi-agent systems often run in containers
  • Phase 3: Local AI Models -- Ollama and other local model runners are best managed via Docker

Getting Help

  • Docker Community Forums: forums.docker.com
  • Docker Discord: discord.com/invite/docker (unofficial but active)
  • Stack Overflow: Tag your questions with docker, docker-compose, or devcontainer
  • GitHub Issues: For bugs in specific images, file issues on the image's GitHub repository

Final Thoughts

Containers are one of those technologies that, once you learn them, you can't imagine working without. They bring order to the chaos of AI development -- where every project needs its own specific combination of runtimes, libraries, drivers, and configurations.

You don't need to memorise every command or option. The cheat sheet above and the official documentation are always there when you need them. What matters is understanding the core concepts: images are blueprints, containers are running instances, volumes persist data, and Compose orchestrates services.

Start simple. Containerise one project. Use a Dev Container for your next piece of work. Run Ollama in Docker instead of installing it directly. Each time, the workflow becomes more natural.

Happy containerising.


Workshop created June 2026 for DreamLab AI. Docker Engine 27.x, Docker Desktop 4.x, Dev Containers specification 0.7+.