What problem does it solve? Writing Dockerfiles that produce large, insecure images is a common problem. This Skill guides the creation of multi-stage Dockerfiles that separate build-time and runtime concerns, resulting in smaller and more secure container images. ## Core Features & Use Cases - Multi-Stage Structure: Separates builder and runtime stages, copying only necessary artifacts between stages with meaningful stage names. - Layer & Image Optimization: Orders layers for maximum build cache reuse, uses minimal base images like slim, Alpine, or distroless variants, and applies .dockerignore rules. - Security Hardening: Enforces non-root users, removes build tools from final images, and keeps build secrets out of runtime layers. - Use Case: You have a Node.js application whose image is over 1GB because it ships dev dependencies and build tools. Use this Skill to restructure the Dockerfile into builder and runtime stages, cutting the final image to a fraction of its size. ## Quick Start Create an optimized multi-stage Dockerfile for my Python application using a slim base image and a non-root user.