docker

Generate production-ready multi-stage Dockerfiles with BuildKit caching and vulnerability scanning.

110|14|Updated May 12, 2026
One-click install
npx skills add https://github.com/EliasOulkadi/shokunin --skill docker-eliasoulkadi
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: docker
Source: https://github.com/EliasOulkadi/shokunin/tree/main/.pack/skills/docker
Command: npx skills add https://github.com/EliasOulkadi/shokunin --skill docker-eliasoulkadi

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires bash, pwsh, grep, trivy, python3, docker, and includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

This Skill prevents bloated, insecure, and flaky Docker images by guiding you to build production-grade containers using multi-stage builds, minimal runtime bases, cache-efficient BuildKit practices, and automated vulnerability scanning.

Core Features & Use Cases

  • Multi-stage Dockerfile optimization: Produces smaller images by separating dependency install, build, and runtime stages, often using distroless or scratch.
  • BuildKit performance + reproducibility: Uses cache mounts and appropriate syntax directives to speed up builds while keeping lockfile-driven installs.
  • Security hardening and scanning: Enforces non-root execution, healthchecks, and recommends CVE scanning with Docker Scout and/or Trivy.
  • Local dev with Docker Compose: Sets up compose watch for hot reload and service health gating for smoother development.
  • Multi-arch build support: Guides use of buildx for cross-platform images and platform-specific considerations.

Quick Start

Ask the agent: "Create a production-ready Dockerfile for my Node.js app using multi-stage builds, a distroless runtime, non-root, a healthcheck, and scan the resulting image for HIGH and CRITICAL CVEs."

Frequently Asked Questions about docker

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a production-ready Dockerfile with multi-stage builds?

To create a production-ready Dockerfile using multi-stage builds, you separate dependency installation, build steps, and runtime stages. This approach uses minimal bases like distroless or scratch to reduce image size while enforcing non-root execution and healthchecks.

What is the best way to harden Docker container security and scan for vulnerabilities?

To harden Docker container security, you enforce non-root execution, configure healthchecks, and scan images for vulnerabilities. You can use Docker Scout or Trivy to verify HIGH and CRITICAL CVEs in your built images before deployment.

How does BuildKit caching improve Docker image build performance?

BuildKit caching improves Docker build performance by using cache mounts and syntax directives to persist package manager downloads across builds. This speeds up subsequent builds while maintaining lockfile-driven, reproducible dependency installations.

Can I build multi-arch Docker images for different platforms?

Yes, you can build multi-arch Docker images for different platforms by using buildx. This guides cross-platform image creation while handling platform-specific considerations to ensure compatibility across architectures.

How do I set up Docker Compose for local development with hot reload?

To set up Docker Compose for local development with hot reload, you configure Compose watch. This enables hot reloads and uses service health gating to ensure smoother, more reliable local development workflows.

Does this Docker optimization approach support Kubernetes or CI-CD pipelines?

No, this Docker optimization approach does not support Kubernetes, CI-CD pipelines, or Terraform workflows. It specifically targets containerization workflows for Dockerfile creation, image size reduction, local development, and post-build vulnerability scanning.