Skills

Docker Destructive Guardrails

Use this skill before running, or recommending, any Docker command that deletes, wipes...

Install

npx skills add docker/skills --skill docker-destructive-guardrails -g -a claude-code -y
Repository
docker/skills609
Category
DevOps
Updated
5d ago
License
Apache-2.0
Context cost
Mediumabout 2,267 tokens
Runs scripts
No, instructions only

What it does

Use this skill before running, or recommending, any Docker command that deletes, wipes, resets, or otherwise irreversibly changes state, even if the user just says to "clean up", "clear the cache", "start fresh", "wipe everything", "nuke it", "reset", "force remove", or "tear down" Docker resources. Covers generic Docker CLI destructive operations not owned by a more specific skill, `docker rm`, `docker rm -f`, `docker container prune`, `docker kill`, `docker system prune`, `docker rmi`/`docker image rm`, `docker image prune -a`, `docker network rm`, `docker network prune`, `docker builder prune`, `docker buildx rm`, `docker context rm`, and standalone (non-Compose) `docker volume rm`/`docker volume prune`. Also indexes destructive commands owned by other Docker skills (Compose, sandbox, Desktop). Core rule, state exactly what will be lost and get explicit confirmation first, except narrow, low-friction Tier 1 container cleanup.

Docker Destructive Command Guardrails

Overview

This skill provides the cross-product policy for handling destructive or irreversible Docker CLI operations: commands that delete data, remove resources, or otherwise cannot be undone. Use it whenever a task could reasonably lead to running one of these commands, even if the user never names the command directly. It covers the generic Docker CLI commands with no home in a more specific skill, and it indexes where other destructive commands (Compose, sandbox, Desktop) are documented.

When to use this skill

Activate this skill when:

  • The user asks to "clean up", "clear the cache", "start fresh", "wipe everything", "nuke it", "reset", "force remove", or "tear down" Docker resources without naming a specific command
  • The agent is considering docker rm, docker rm -f, docker container prune, docker kill, docker stop, docker system prune, docker rmi, docker image rm, docker image prune -a, docker network rm, docker network prune, docker builder prune, docker buildx rm, docker context rm, or standalone (non-Compose) docker volume rm/docker volume prune as a fix for an unrelated problem (disk space, a stuck container, a stale network, a broken build cache, an old builder or volume)
  • The user wants a cross-product overview of destructive commands across Docker skills

Do not use this skill when

Do not use this skill when:

  • The destructive command in question is Compose-specific (docker compose down -v, docker compose rm -v, docker volume rm/docker volume prune in a Compose project), use docker-compose-patterns directly, which owns that guidance in full detail
  • The task is authoring or reviewing a Dockerfile or compose.yaml with no cleanup or deletion involved
  • The operation is non-Docker (git, filesystem, cloud resources), this skill covers Docker CLI operations only

Core guidance

Read the whole SKILL.md on GitHub

More in DevOps