- Alpine Optimized
A Python FastAPI Dockerfile on Alpine that strips libraries, bytecode, and unused stdlib modules to get an image under 110MB with a non-root user.
- Optimization Techniques
An index of Dockerfile optimization approaches for Python applications, comparing distroless, Alpine, wheel-based offline, and UV plus tini builds.
- UV Alpine Tini
A simple, maintainable Python Dockerfile using UV on Alpine with tini as init, plus a cross-Dockerfile comparison, best practices, and conclusion for the Python series.
- UV Distroless
A multi-arch Python Dockerfile that installs dependencies with UV and runs on a distroless Debian 12 base with manually copied shared libraries for high security and small size.
- Wheel Offline
A Python Dockerfile that builds all dependencies into wheels in a builder stage, auto-patches vulnerable versions, and installs them offline in a slim runtime.