Logo van MCP-Compose

MCP-Compose

Community
phildougherty

Compose, manage, and run MCP servers as Docker containers. With a Unified API gateway built in.

Uitgeverphildougherty
Repositorymcp-compose
TaalGo
Forks
5
Sterren
58
Beschikbare tools
0
Transporttypestdio
Categorieën
LicentieAGPL-3.0
Links
  • Koppel tools aan AI-workflows

    MCP-Compose biedt MCP-functionaliteit die compatibele AI-clients en agenten kunnen gebruiken.

  • 0 beschikbare tools

    Bekijk hieronder de aanroepbare acties, inclusief namen en beschrijvingen als de server die beschikbaar stelt.

  • Configuratie om direct te kopiëren

    Gebruik de installatievoorbeelden om deze server in je favoriete MCP-client te configureren.

  • Indicatoren van opensource-interesse

    58 sterren en 5 forks in de gekoppelde repository.

MCP-Compose

codecov Go Report Card License: AGPL v3 Release

Docker Compose for Model Context Protocol servers. Run multiple MCP servers with unified configuration, HTTP proxy, and container orchestration.

MCP-Compose Demo

Features

  • Docker Compose-style YAML configuration
  • HTTP proxy with automatic protocol translation (STDIO → HTTP)
  • Native support for Docker and Podman
  • Session management and connection pooling
  • Built-in dashboard and monitoring
  • OpenAPI spec generation

Installation

bash
git clone https://github.com/phildougherty/mcp-compose.git
cd mcp-compose
make build

# Add to PATH
sudo cp build/mcp-compose /usr/local/bin/
# OR
export PATH="$PWD/build:$PATH"

Quick Start

Interactive Setup

bash
mcp-compose init

Follow the prompts to create your configuration.

Manual Setup

Create mcp-compose.yaml:

yaml
version: '1'
servers:
  filesystem:
    protocol: stdio
    command: npx
    args:
      - "-y"
      - "@modelcontextprotocol/server-filesystem"
      - "/tmp"
    capabilities: [resources, tools]

Start servers:

bash
mcp-compose up

Start the HTTP proxy:

bash
mcp-compose proxy --port 9876

Test it:

bash
curl http://localhost:9876/api/servers

Working Examples

Basic - Filesystem + Memory

yaml
version: '1'
servers:
  filesystem:
    protocol: stdio
    command: npx
    args:
      - "-y"
      - "@modelcontextprotocol/server-filesystem"
      - "${HOME}"
    capabilities: [resources, tools]
    volumes:
      - "${HOME}:${HOME}:ro"

  memory:
    protocol: stdio
    command: npx
    args:
      - "-y"
      - "@modelcontextprotocol/server-memory"
    capabilities: [resources, tools]

With Web Search

Add Brave Search (requires API key from https://brave.com/search/api/):

yaml
  brave-search:
    protocol: stdio
    command: npx
    args:
      - "-y"
      - "@modelcontextprotocol/server-brave-search"
    capabilities: [tools]
    env:
      BRAVE_API_KEY: "${BRAVE_API_KEY}"
bash
export BRAVE_API_KEY="your-api-key"
mcp-compose up

See examples/ for more configurations.

Commands

Service Management

bash
mcp-compose up                 # Start all services
mcp-compose up filesystem      # Start specific service
mcp-compose down               # Stop all services
mcp-compose down filesystem    # Stop specific service
mcp-compose restart            # Restart all services
mcp-compose ps                 # List service status
mcp-compose logs filesystem    # View logs

System Services

System services are infrastructure components (proxy, dashboard, task-scheduler, memory).

bash
mcp-compose system up          # Start system services
mcp-compose system down        # Stop system services
mcp-compose system ps          # List system services
mcp-compose system status      # Health overview
mcp-compose system logs proxy  # View system logs

Proxy

bash
mcp-compose proxy --port 9876              # Start proxy
mcp-compose proxy --api-key $(openssl rand -hex 32)  # With authentication

Dashboard

bash
mcp-compose dashboard          # Start web dashboard
# Access at http://localhost:3111

Configuration

bash
mcp-compose init               # Interactive setup wizard
mcp-compose validate           # Validate config file
mcp-compose create-config --type claude  # Generate client config

Configuration Reference

Basic Structure

yaml
version: '1'

# Optional: proxy authentication
proxy_auth:
  enabled: true
  api_key: "${MCP_API_KEY}"

servers:
  my-server:
    protocol: string           # stdio, http, sse
    command: string            # Executable (e.g., npx, python, node)
    args: [string]             # Command arguments
    capabilities: [string]     # tools, resources, prompts, sampling
    env:                       # Environment variables
      KEY: value
    volumes:                   # Volume mounts
      - "host:container:mode"

Protocol Types

STDIO (most common for NPM packages):

yaml
servers:
  my-server:
    protocol: stdio
    command: npx
    args: ["-y", "@modelcontextprotocol/server-filesystem", "/tmp"]

HTTP:

yaml
servers:
  my-server:
    protocol: http
    http_port: 8080

SSE (Server-Sent Events):

yaml
servers:
  my-server:
    protocol: sse
    http_port: 8080
    sse_path: /events

Volume Mounts

yaml
volumes:
  - "/host/path:/container/path:ro"   # Read-only
  - "/host/path:/container/path:rw"   # Read-write
  - "${HOME}/code:/workspace:ro"      # Environment variables

Environment Variables

In your config:

yaml
env:
  API_KEY: "${MY_API_KEY}"

In your shell:

bash
export MY_API_KEY="secret"
mcp-compose up

Security

Never commit secrets to your config file. Use environment variables:

bash
# Generate secure keys
export MCP_API_KEY=$(openssl rand -hex 32)
export OAUTH_CLIENT_SECRET=$(openssl rand -hex 32)

Reference in config:

yaml
proxy_auth:
  api_key: "${MCP_API_KEY}"

Client Integration

Claude Desktop

Generate config:

bash
mcp-compose create-config --type claude --output ./claude-config

Copy contents to Claude Desktop settings.

Direct HTTP

bash
# List tools
curl -X POST http://localhost:9876/filesystem \
  -H "Content-Type: application/json" \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'

# Call tool
curl -X POST http://localhost:9876/filesystem \
  -H "Content-Type: application/json" \
  -d '{
    "jsonrpc":"2.0",
    "id":1,
    "method":"tools/call",
    "params":{
      "name":"read_file",
      "arguments":{"path":"/tmp/test.txt"}
    }
  }'

Troubleshooting

Check Service Status

bash
mcp-compose ps
mcp-compose system status

View Logs

bash
mcp-compose logs filesystem
mcp-compose system logs proxy

Validate Configuration

bash
mcp-compose validate

Common Issues

Port already in use:

bash
lsof -i :9876
mcp-compose proxy --port 9877  # Use different port

Container not starting:

bash
mcp-compose logs my-server     # Check logs
docker ps -a                   # Check container status

Authentication errors:

bash
echo $MCP_API_KEY              # Verify key is set

Requirements

  • Docker 20.10+ or Podman 3.0+
  • Linux, macOS, or Windows with WSL2
  • Go 1.19+ (for building from source)

Architecture

┌──────────────────────────────┐
│     MCP-Compose Proxy        │
│  (HTTP API + Authentication) │
└──────────────┬───────────────┘
               │
        ┌──────┼──────┐
        │      │      │
    ┌───▼──┐ ┌─▼──┐ ┌▼───┐
    │ FS   │ │ Mem│ │Search│
    │STDIO │ │HTTP│ │ SSE  │
    └──────┘ └────┘ └──────┘

License

GNU Affero General Public License v3.0 - see LICENSE.

Links

Installatie

TypingMind
Vereisten:

Node.js 18+

{
  "mcpServers": {
    "phildougherty-mcp-compose": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-compose"
      ]
    }
  }
}

Gebruik MCP-Compose MCP met meerdere AI-modellen

TypingMind koppelt MCP-tools aan de werkruimte. Zodra MCP-Compose is verbonden, kun je deze dus met verschillende AI-modellen in TypingMind gebruiken, zonder de verbinding voor elk model apart in te stellen. Deze MCP-integratie draait lokaal via de TypingMind MCP-connector op je apparaat.

Installatiehandleiding voor de lokale connector

Gebruik dit als de MCP-server toegang nodig heeft tot lokale bestanden, apps of privébronnen op je computer.

1

Open de MCP-instellingen

Ga in TypingMind naar Instellingen, Geavanceerde instellingen en vervolgens Model Context Protocol. Kies daar Connector instellen.

  1. Open TypingMind in je browser.
  2. Klik op het pictogram Instellingen.
  3. Ga naar Geavanceerde instellingen.
  4. Open het gedeelte Model Context Protocol.
  5. Klik op Connector instellen en kies Dit apparaat.
Instelscherm voor de TypingMind MCP-connector met Dit apparaat geselecteerd
2

Voer de connectoropdracht uit

Kies Dit apparaat, kopieer de opdracht uit TypingMind en voer deze uit in Terminal. Laat het proces draaien zolang je MCP gebruikt.

  1. Kopieer de installatieopdracht die TypingMind toont.
  2. Open Terminal op macOS of Windows Terminal op Windows.
  3. Plak de opdracht en voer deze uit.
  4. Keur de pakketinstallatie goed als Terminal vraagt of je wilt doorgaan.
  5. Laat het proces in het Terminal-venster draaien zolang je MCP-tools gebruikt.
3

Voeg MCP-Compose toe als server

Klik op Servers bewerken zodra de connectorstatus Gereed is en plak de MCP-serverconfiguratie.

  1. Wacht tot de connectorstatus Gereed aangeeft.
  2. Klik op Servers bewerken.
  3. Plak de MCP-serverconfiguratie van MCP-Compose.
  4. Sla de serverlijst op.
  5. Vernieuw om te controleren of de connector nog steeds klaar is voor gebruik.
MCP-instellingen van TypingMind met een actieve server en de knop Servers bewerken
{
  "mcpServers": {
    "phildougherty-mcp-compose": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-compose"
      ]
    }
  }
}
4

Gebruik de verbinding met verschillende modellen

Sla de serverlijst op, open Plug-ins en schakel de MCP-tools van MCP-Compose in. Selecteer vervolgens een ondersteund AI-model in TypingMind en gebruik de tools in de chat of wijs ze toe aan een AI-agent.

  1. Open de pagina Plug-ins in TypingMind.
  2. Schakel de MCP-tools van MCP-Compose in.
  3. Start een chat en kies het AI-model dat je wilt gebruiken.
  4. Gebruik de MCP-tools in een chat of wijs ze toe aan een AI-agent.
  5. Schakel wanneer nodig over naar een ander AI-model zonder opnieuw verbinding te maken met MCP.
TypingMind-chat met ingeschakelde MCP-tools en een geselecteerd AI-model
Kun je MCP-Compose gebruiken om me hiermee te helpen?
MCP-Compose
Zeker. Ik heb het gelezen.
Dit vond ik met MCP-Compose.

Veelgestelde vragen

Waarvoor wordt de MCP-server MCP-Compose gebruikt?

MCP-Compose is een MCP-server waarmee compatibele AI-clients verbinding kunnen maken met externe tools en context. In TypingMind hoef je deze MCP-server maar één keer toe te voegen om de tools beschikbaar te maken in je AI-werkruimte.

Kan ik MCP-Compose MCP met meerdere AI-modellen in TypingMind gebruiken?

Ja. TypingMind verbindt MCP-tools op werkruimteniveau. Daardoor kun je MCP-Compose gebruiken met verschillende AI-modellen, zoals Claude, ChatGPT, Gemini of andere modellen die je in TypingMind hebt ingesteld, zonder de MCP-server voor elk model afzonderlijk in te stellen.

Waarom MCP-Compose MCP gebruiken met TypingMind?

TypingMind is een van de beste interfaces voor chats met LLM's, omdat het meerdere AI-modellen, prompts, plug-ins, AI-agenten, API-sleutels en MCP-tools samenbrengt in één werkruimte. Als MCP-Compose verbonden is, kun je de MCP-tools ervan gebruiken met je favoriete modellen en je chatworkflow overzichtelijk houden in TypingMind.

Hoe verbind ik MCP-Compose MCP met TypingMind?

MCP-Compose werkt via de lokale MCP-connector van TypingMind. Dit is de beste optie als de MCP-server toegang nodig heeft tot lokale bestanden, desktopapps, opdrachtregeltools of privébronnen op je computer.

Welke tools biedt MCP-Compose MCP in TypingMind?

MCP-Compose biedt MCP-functies die je kunt inschakelen via de pagina Plug-ins in TypingMind. Je kunt ze gebruiken in chats of toewijzen aan AI-agenten.

Moet ik mijn API-sleutels delen met TypingMind om MCP-Compose MCP te gebruiken?

Nee. TypingMind werkt in de eerste plaats lokaal en laat je de controle houden over je modelaanbieders, API-sleutels, prompts en MCP-configuratie. Als MCP-Compose authenticatie vereist, voeg je bij het maken van de verbinding de vereiste headers, OAuth-instellingen of lokale configuratie voor die MCP-server toe.

Gerelateerde MCP-servers

Toon alles

Maak nu je eigen AI-werkruimte

Schrijf je in voor onze nieuwsbrief en blijf op de hoogte van nieuwe functies en toekomstige weggeefacties 👇