Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

smith-mcpdef

БесплатноБез исполняемых скриптовНе проверен

Generate MCP environment definition for MCPSmith with Docker and Node.js verification

jmaglyот jmagly★ 233 звезды на GitHub

Об этом скилле

MCP Environment Definition Generator

Generate an MCP environment definition file that catalogs Docker and Node.js capabilities for the MCPSmith agent. This file describes the local environment's ability to build and run containerized MCP servers.

Arguments

  • --output <path> - Output file path (default: .aiwg/smiths/mcp-definition.yaml)
  • --verify-only - Verify existing definition without regenerating
  • --update - Update existing definition with any changes
  • --create-network - Create the Docker network if it doesn't exist

Workflow

Step 1: Ensure Directory Structure

Create the mcpsmith directory if it doesn't exist:

mkdir -p .aiwg/smiths/mcpsmith/tools
mkdir -p .aiwg/smiths/mcpsmith/implementations
mkdir -p .aiwg/smiths/mcpsmith/templates
mkdir -p .aiwg/smiths/mcpsmith/images

Step 2: Check Docker Availability

Verify Docker is installed and running:

# Check Docker CLI
docker --version

# Check Docker daemon is running
docker info 2>/dev/null | head -20

# Check Docker Compose
docker compose version 2>/dev/null || docker-compose --version 2>/dev/null

Required: Docker must be available and running for MCPSmith to function.

Step 3: Check Node.js Environment

Verify Node.js is available:

# Node.js version
node --version

# npm version
npm --version

# Check for MCP SDK (in project or global)
npm list @modelcontextprotocol/sdk 2>/dev/null || npm list -g @modelcontextprotocol/sdk 2>/dev/null

Step 4: Check Docker Images

Verify base images are accessible:

# Check if base images exist locally or can be pulled
docker image inspect node:20-alpine 2>/dev/null || echo "node:20-alpine not cached"
docker image inspect node:20-slim 2>/dev/null || echo "node:20-slim not cached"

Step 5: Check/Create Docker Network

Verify or create the MCP network for container communication:

# Check if network exists
docker network ls | grep aiwg-mcp-network

# Create if missing (only with --create-network flag)
docker network create aiwg-mcp-network 2>/dev/null || true

Step 6: Determine Available Port Range

Find available ports in the configured range:

# Check ports 9100-9199 for availability
for port in $(seq 9100 9110); do
  nc -z localhost $port 2>/dev/null || echo "$port available"
done

Step 7: Generate YAML Output

Create .aiwg/smiths/mcp-definition.yaml:

# MCP Environment Definition for MCPSmith
# Generated: <timestamp>
# Platform: <os> <version>

docker:
  available: true|false
  version: "<docker version>"
  compose_version: "<compose version>"
  runtime: "<containerd|runc>"
  daemon_running: true|false

node:
  available: true|false
  version: "<node version>"
  npm_version: "<npm version>"

mcp:
  sdk_available: true|false
  sdk_version: "<version or null>"
  spec_version: "2025-11-25"
  transports:
    - stdio
    # - http  # if supported

base_images:
  node_alpine:
    image: "node:20-alpine"
    cached: true|false
  node_slim:
    image: "node:20-slim"
    cached: true|false

network:
  name: "aiwg-mcp-network"
  exists: true|false
  driver: "bridge"

ports:
  range_start: 9100
  range_end: 9199
  available: [9100, 9101, ...]  # First 10 available ports

capabilities:
  can_build_images: true|false
  can_run_containers: true|false
  can_create_networks: true|false
  stdio_transport: true|false
  http_transport: true|false

Step 8: Report Summary

Output a summary of the MCP environment:

MCP Environment Definition Generated
=====================================
Docker: Available (v24.0.7)
  - Daemon: Running
  - Compose: v2.23.0
  - Runtime: containerd

Node.js: Available (v20.10.0)
  - npm: v10.2.0
  - MCP SDK: @modelcontextprotocol/[email protected]

Base Images:
  - node:20-alpine: Cached
  - node:20-slim: Not cached (will pull on first use)

Network:
  - aiwg-mcp-network: Exists

Port Range: 9100-9199
  - Available ports: 9100, 9101, 9102, ... (10 shown)

Capabilities:
  ✓ Can build images
  ✓ Can run containers
  ✓ Can create networks
  ✓ Stdio transport
  ✗ HTTP transport (not configured)

Output: .aiwg/smiths/mcp-definition.yaml

Error Conditions

Docker Not Available

Error: Docker is not available.

MCPSmith requires Docker to build and run MCP tool containers.

Please install Docker:
  - Linux: https://docs.docker.com/engine/install/
  - macOS: https://docs.docker.com/desktop/mac/install/
  - Windows: https://docs.docker.com/desktop/windows/install/

After installation, ensure Docker daemon is running:
  sudo systemctl start docker  # Linux
  open -a Docker               # macOS

Docker Daemon Not Running

Error: Docker daemon is not running.

Start Docker:
  - Linux: sudo systemctl start docker
  - macOS: Open Docker Desktop
  - Windows: Start Docker Desktop

Then re-run: /smith-mcpdef

Node.js Not Available

Warning: Node.js is not available on the host.

MCPSmith can still build containers (Node.js included in image),
b
Полный SKILL.md на GitHub

Установить smith-mcpdef в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

FAQ

Что делает скилл smith-mcpdef?

Generate MCP environment definition for MCPSmith with Docker and Node.js verification

Как установить скилл smith-mcpdef?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл smith-mcpdef запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить smith-mcpdef с