@tank/docker-compose-cheatsheet

Organize Docker Compose commands and YAML reference material for development workflows.

1|1|Updated Feb 20, 2026
One-click install
npx skills add https://github.com/tankpkg/packages --skill tank-docker-compose-cheatsheet
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: @tank/docker-compose-cheatsheet
Source: https://github.com/tankpkg/packages/tree/main/skills/docker-compose-cheatsheet
Command: npx skills add https://github.com/tankpkg/packages --skill tank-docker-compose-cheatsheet

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill helps engineers quickly find the right Docker Compose command or YAML pattern without digging through documentation, reducing setup friction and startup confusion in local development and operations.

Core Features & Use Cases

  • Lifecycle Commands: Covers starting, stopping, rebuilding, inspecting, and cleaning up Compose-based stacks.
  • Compose File Guidance: Explains service definitions, environment variables, ports, volumes, networks, profiles, and healthchecks.
  • Practical Workflow Support: Helps with common tasks like entering containers, running one-off commands, handling dependencies, and keeping local development readable and reliable.
  • Use Case: A developer can use this Skill to decide whether to use build or image, how to wire service readiness, and how to cleanly reset a broken local stack.

Quick Start

Ask for a concise Docker Compose cheat sheet that explains the commands, YAML fields, and recommended patterns for your local development stack.

Frequently Asked Questions about @tank/docker-compose-cheatsheet

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

FAQPage Schema
How do I configure Docker Compose healthchecks and service startup ordering?

Docker Compose healthchecks and startup ordering are configured using the healthcheck and depends_on fields in your compose YAML. You can define custom test commands, intervals, and retries, then use depends_on with condition: service_healthy to ensure services start only when dependencies pass their healthcheck.

What is the difference between build and image in a Docker Compose service definition?

In a Docker Compose service definition, the build key instructs Compose to construct an image from a specified Dockerfile context, whereas the image key pulls a pre-built image from a registry. You use build for local development changes and image for deploying ready-to-use container images.

How do I use Docker Compose profiles to manage local development environments?

Docker Compose profiles let you group services and start selective environments by assigning a profiles key to services in your compose YAML. Running Compose with the --profile flag starts only the services matching that profile, allowing you to isolate optional or environment-specific stacks.

What is the best way to clean up and reset a broken Docker Compose stack?

The best way to reset a broken Docker Compose stack is running docker compose down with the -v flag to remove containers, networks, and named volumes. This clears conflicting state and persistent data, allowing you to cleanly rebuild and restart your local development environment.

How do I run one-off commands and get shell access inside a Docker Compose container?

To run one-off commands or get shell access in a Docker Compose container, use docker compose exec followed by the service name and your desired command. Adding /bin/sh or /bin/bash opens an interactive shell inside the running service for direct troubleshooting.

Does Docker Compose support persistent data with volumes and custom networks?

Yes, Docker Compose supports persistent data and custom networks through top-level volumes and networks keys in the compose YAML. You define named volumes and bridge networks, then reference them in service definitions to maintain data state and control service communication.