mcp -docker
MCP server with Docker, Redis, and TimescaleDB
claude mcp add --transport stdio chuckwilliams37-mcp-server-docker docker compose up -d \ --env DOCKER_HOST="optional: remote daemon host, e.g., tcp://127.0.0.1:2375" \ --env COMPOSE_PROJECT_NAME="optional: project name for docker-compose"
How to use
This MCP server stack is Docker-based and integrates Redis for caching and TimescaleDB for time-series data, orchestrated via Docker Compose. The server exposes a FastAPI application that serves MCP endpoints and utilities to manage and query model-context data. Redis handles short-term caching to speed up frequent requests, while TimescaleDB stores long-term time-series MCP data for efficient querying and analytics. The deployment is managed with a docker-compose.yml file, and you can enable automatic restarts and system-wide availability through a systemd service as described in the repo. To interact with the server, you can use the HTTP endpoints exposed by FastAPI (typically on port 8080 as documented in the repo) and leverage the provided scripts to bootstrap, initialize, or push updates to your MCP repository.
How to install
Prerequisites:
- Docker and Docker Compose installed on your system
- Git installed
- Optional: Zsh (with Oh-My-Zsh) for a smoother shell experience
Step-by-step installation:
-
Clone the repository: git clone https://github.com/chuckwilliams37/mcp-server-docker.git cd mcp-server-docker
-
Configure environment variables: cp .env.example .env Edit .env to suit your environment (ports, credentials, etc.).
-
Build and start the containers: docker compose build docker compose up -d
-
Access the MCP server: http://localhost:8080
Optional: set up auto-restart on reboot using systemd (as described in the README):
- Create and edit a systemd service file (e.g., /etc/systemd/system/mcp-docker.service)
- Enable and start the service: sudo systemctl daemon-reload sudo systemctl enable mcp-docker sudo systemctl start mcp-docker
Additional notes
Notes and tips:
- The server relies on Docker Compose to orchestrate the FastAPI app, Redis, and TimescaleDB containers. Ensure your docker-compose.yml is properly configured for your environment and that ports are accessible (default 8080 for FastAPI in this setup).
- Keep an .env file to manage environment-specific settings (database credentials, Redis URL, etc.).
- If you modify ports or database credentials, update docker-compose.yml and .env accordingly and restart the containers.
- The included scripts (bootstrap, init-repo, push-repo, setup-mcpserver) help automate setup and repository management; run with executable permissions (chmod +x) as shown in README.
- If you need to run a remote Docker daemon, configure DOCKER_HOST and related Docker client settings; ensure network policies allow container communication between Redis, TimescaleDB, and the FastAPI service.
Related MCP Servers
shellfirm
Terminal guardrails for humans and AI agents — intercepts dangerous commands with context-aware challenges before the damage is done.
mcp-cli
mcpc is a CLI client for MCP. It supports persistent sessions, stdio/HTTP, OAuth 2.1, JSON output for code mode, proxy for AI sandboxes, and much more.
mcp-shell
Give hands to AI. MCP server to run shell commands securely, auditably, and on demand.
hackerone-graphql
MCP server for the HackerOne GraphQL API
terminal
A minimal, zero-dependency terminal MCP (Model Context Protocol) client built for coding agents like OpenAI Codex.
opensearch
OpenSearch 3.0 with MCP Server