Skill / SKILL.md

Docker Build Strategies

docker/skills

Use this skill when writing, reviewing, or optimizing Dockerfiles, even if the user just says their image is too large, their build is slow, or they need to harden a container for production. Covers multi-stage builds, layer caching, .dockerignore, non-root users, and image size optimization.
3 views 658 repository stars 0 commentsUpdated Nov 27, 2026
Overview

Use this skill when writing, reviewing, or optimizing Dockerfiles, even if the user just says their image is too large, their build is slow, or they need to harden a container for production. Covers multi-stage builds, layer caching, .dockerignore, non-root users, and image size optimization.

Installation & variants

Download the repository, including the skill’s supporting files.

git clone -- 'https://github.com/docker/skills' skill-source

Use the complete skill-source/skills/docker-build-strategies directory with your client’s skill installer.

  • skills/docker-build-strategies

    main · SKILL.md

    Open installation source

    Source directory recorded from the imported repository path

Source directory skills/docker-build-strategies

Compatibility & requirements

Declared compatibility

Requires Docker 23.0+ (BuildKit default). On Docker 20.10–22.x, set DOCKER_BUILDKIT=1 before building.

Source instructions
Read source instructions

Open to load source instructions

Original SKILL.md

Open to load the original file

Source & validation
Source status
Awaiting source check
Format validation
Format valid
Checked at
Pending source check
Content SHA-256
686e67c3230b587ebbf1b1add902eb4db8346175ba6eecd35c2e77178e8fca4b
Discussion
Comments Be the First to Comment

Please log in to comment

    No comments yet

Related skills