ywc-docker-isolate

Derive deterministic Docker port blocks and project names per Git worktree.

8|1|Updated May 13, 2026
One-click install
npx skills add https://github.com/yongwoon/ywc-agent-toolkit --skill ywc-docker-isolate
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ywc-docker-isolate
Source: https://github.com/yongwoon/ywc-agent-toolkit/tree/main/claude-code/skills/ywc-docker-isolate
Command: npx skills add https://github.com/yongwoon/ywc-agent-toolkit --skill ywc-docker-isolate

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires docker, bash, python3, git, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This skill resolves host-port collisions that occur when running multiple Docker stacks simultaneously across different Git worktrees, preventing the common port is already allocated error.

Core Features & Use Cases

  • Deterministic Namespacing: Automatically derives unique host-port blocks and project names based on the task name, ensuring no two worktrees ever conflict.
  • Immutable Infrastructure: Manages isolation via local environment files without ever modifying your committed compose or environment configuration files.
  • Lifecycle Management: Provides integrated setup, teardown, and audit capabilities to ensure clean Docker environments and prevent stale, resource-hogging containers.

Quick Start

Use the ywc-docker-isolate skill to apply port isolation to the current task worktree and audit for any residual stacks.

Frequently Asked Questions about ywc-docker-isolate

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

FAQPage Schema
How do I prevent Docker host-port collisions when running parallel Git worktrees?

Prevent Docker host-port collisions in parallel Git worktrees by deriving deterministic, per-worktree port blocks and project names. This manages isolation via local environment files without modifying committed compose or environment configuration files.

What is deterministic Docker port isolation for parallel worktrees?

Deterministic Docker port isolation is a technique that derives unique host-port blocks and project names based on the task name. It eliminates the 'port is already allocated' error by managing environment-local port mappings across concurrent stacks.

How do I apply port isolation to a Docker Compose stack without modifying committed files?

Apply port isolation to Docker Compose stacks by managing isolation via local environment files. This approach maintains immutable infrastructure by never modifying your committed compose or environment configuration files.

Does Docker port isolation work with standard Docker Compose for concurrent stacks?

Yes, Docker port isolation works with multi-task development environments using Docker Compose where concurrent stacks are required. It requires bash, docker, python3, and git to manage environment-local port mappings and container lifecycles.

How do I audit and clean up stale Docker containers across multiple worktrees?

Audit and clean up stale Docker containers across multiple worktrees using integrated teardown and audit capabilities. These lifecycle management features ensure clean Docker environments and prevent stale, resource-hogging containers from persisting.

Why does running multiple Docker Compose stacks in different worktrees cause port is already allocated errors?

Running multiple Docker Compose stacks in different worktrees causes 'port is already allocated' errors because concurrent stacks attempt to bind to the same host ports. Deriving unique, per-worktree port blocks eliminates these collisions.