docker-build
Installation
SKILL.md
Docker Build for Python/FastAPI Applications
Overview
Containerize Python and FastAPI applications using Docker with
production-grade multi-stage builds, layer caching, security hardening, and
Docker Compose orchestration. All patterns target Python 3.12+, use uv for
dependency management, and follow the principle of minimal, reproducible
images.
Refer to the asset templates bundled with this skill for ready-to-use starting points:
assets/Dockerfile.fastapi-- production multi-stage Dockerfileassets/Dockerfile.dev-- development Dockerfile with hot reloadassets/docker-compose.yml-- Compose stack with PostgreSQL and Redisassets/.dockerignore-- ignore rules for lean build contexts