MCP-Servers
This project sets up Model Context Protocol (MCP) servers using Docker Compose.
Added on 3/28/2025
MCP Servers
This project sets up Model Context Protocol (MCP) servers using Docker Compose.
Included Servers
- Git - Read, search, and manipulate Git repositories
- Filesystem - Secure file operations with configurable access controls
- PostgreSQL - Database access with schema inspection
- Memory - Knowledge graph-based persistent memory system
- Inspector - GUI tool for managing and debugging MCP servers (run locally with npx)
Setup
- Initialize the repository:
./scripts/init-repo.sh
This will:
- Set the correct Node.js version using nvm
- Install MCP Inspector globally
- Start the containerized servers:
docker compose up -d
- Start the MCP Inspector locally:
./scripts/start-inspector.sh
- Stop the MCP Inspector:
./scripts/stop-inspector.sh
- Stop the containerized servers:
docker compose down
Directory Structure
docker-data/- Data directories for each MCP serverdocker-files/- Dockerfile resourcesscripts/- Utility scripts for managing servicesinit-repo.sh- Initialize the repository with correct Node.js and packagesstart-inspector.sh- Start the MCP Inspector in backgroundstop-inspector.sh- Stop the MCP Inspector- templates:
template-start-mcp-server.sh- Template for creating start scripts for MCP serverstemplate-stop-mcp-server.sh- Template for creating stop scripts for MCP servers
Configuration
Each server can be configured through environment variables in the docker-compose.yml file.
Accessing the Inspector
The MCP Inspector will be available at http://localhost:5173 after starting it with the script.
Logs
- Inspector logs are stored in
./docker-data/inspector/inspector.log
Adding New MCP Servers
To add a new MCP server that runs locally (non-dockerized):
- Copy the template scripts:
cp scripts/template-start-mcp-server.sh scripts/start-newserver.sh
cp scripts/template-stop-mcp-server.sh scripts/stop-newserver.sh
chmod +x scripts/start-newserver.sh scripts/stop-newserver.sh
- Edit both scripts to set:
SERVER_NAME- Name of your serverNPX_COMMAND- NPX command to run the serverPORT- Port the server runs on
- Make sure to install the server package globally or specify it in the NPX command.
Similar Resources
Developer Tools