Agent skill

multi-stage-dockerfile

Create optimized multi-stage Dockerfiles for any language or framework

GitHub68,948★ · +463/wk · 2 repos on radarProfile →
copilotMIT
Install
npx skills add github/awesome-copilot --skill multi-stage-dockerfile --agent copilot

Same command for any agent — swap --agent for claude-code, codex, cursor.

Facts
Files in the skill folder: 1
SKILL.md size: 2 KB
Bundled scripts: none
Path: skills/multi-stage-dockerfile/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 37,432 · +281 this week
Language: Python

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

Your goal is to help me create efficient multi-stage Dockerfiles that follow best practices, resulting in smaller, more secure container images. ## Multi-Stage Structure - Use a builder stage for compilation, dependency installation, and other build-time operations - Use a separate runtime stage that only includes what's needed to run the application - Copy only the necessary artifacts from the builder stage to the runtime stage - Use meaningful stage names with the `AS` keyword (e.g., `FROM node:18 AS builder`) - Place stages in logical order: dependencies → build → test → runtime ## Base Images - Start with official, minimal base images when possible - Specify exact version tags to ensure reproducible builds (e.g., `python:3.11-slim` not just `python`) - Consider distroless images for runtime stages where appropriate - Use Alpine-based images for smaller footprints when compatible with your application - Ensure the runtime image has the minimal necessary dependencies ## Layer Optimization - Organize commands to maximize layer caching - Place commands that change frequently (like code changes) after commands that change less frequently (like dependency installation) - Use `.docker

What's inside
Steps it walks through
  1. Multi-Stage Structure
  2. Base Images
  3. Layer Optimization
  4. Security Practices
  5. Performance Considerations
More from awesome-copilot
All skills →
About this skill
What does the multi-stage-dockerfile skill do?

Create optimized multi-stage Dockerfiles for any language or framework

How do I install it?

Run `npx skills add github/awesome-copilot --skill multi-stage-dockerfile --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From github/awesome-copilot, a repository with 37,432 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going