MCP Server with Docker, Redis, and TimescaleDB
Provides caching mechanisms for the MCP server.
Provides time-series database capabilities built on PostgreSQL for efficient data management.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@MCP Server with Docker, Redis, and TimescaleDBquery the last hour of CPU usage data"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
๐ MCP Server with Docker, Redis, and TimescaleDB
This repository sets up a Model Context Protocol (MCP) Server using Docker, integrating Redis and TimescaleDB for efficient data management.
๐ ๏ธ Features
FastAPI: Serves as the web framework for the MCP server.
Redis: Provides caching mechanisms.
TimescaleDB: A time-series database built on PostgreSQL.
Docker Compose: Orchestrates multi-container Docker applications.
Environment Variables: Configurable via
.envfile.Systemd Service: Ensures the server auto-starts on reboot.
๐ Prerequisites
Docker and Docker Compose installed on your system.
Git for version control.
Zsh with Oh-My-Zsh (optional, for enhanced shell experience).
๐ Repository Structure
mcp-server-docker/
โโโ app/
โ โโโ app.py
โโโ .env.example
โโโ docker-compose.yml
โโโ Dockerfile
โโโ requirements.txt
โโโ scripts/
โ โโโ bootstrap-mcp.sh
โ โโโ full-bootstrap-mcp.sh
โ โโโ init-repo.sh
โ โโโ push-repo.sh
โ โโโ setup-mcpserver.sh
โโโ README.md๐ Setup Instructions
Clone the Repository:
git clone https://github.com/chuckwilliams37/mcp-server-docker.git cd mcp-server-dockerConfigure Environment Variables:
cp .env.example .envModify
.envas needed.Build and Start the Containers:
docker compose build docker compose up -dAccess the MCP Server:
http://localhost:8080
๐ Auto-Restart on Reboot
Create a systemd service to keep your app alive:
sudo nano /etc/systemd/system/mcp-docker.servicePaste:
[Unit]
Description=MCP Docker Compose App
Requires=docker.service
After=docker.service
[Service]
WorkingDirectory=/home/youruser/mcp-server-docker
ExecStart=/usr/bin/docker compose up -d
ExecStop=/usr/bin/docker compose down
Restart=always
TimeoutStartSec=0
[Install]
WantedBy=multi-user.targetEnable it:
sudo systemctl daemon-reload
sudo systemctl enable mcp-docker
sudo systemctl start mcp-docker๐งช Scripts
The scripts/ directory contains utility scripts to automate infrastructure tasks.
๐ ๏ธ scripts/full-bootstrap-mcp.sh
๐ก Use this on a fresh Ubuntu VM to fully prepare it for MCP deployment. It:
Installs system dependencies (Docker, Git, Zsh, UFW, Fail2Ban, etc.)
Sets up
oh-my-zshwith thejonathanthemeConfigures Remote Desktop with XFCE + XRDP
Clones the MCP repo
Builds and launches the app with
docker composeAdds a systemd service to relaunch containers on reboot
chmod +x scripts/full-bootstrap-mcp.sh
./scripts/full-bootstrap-mcp.sh๐ scripts/init-repo.sh
Initializes a new local Git repository and commits the current directory:
chmod +x scripts/init-repo.sh
./scripts/init-repo.sh๐ค scripts/push-repo.sh
Pushes your local repo to a remote (update URL first):
chmod +x scripts/push-repo.sh
./scripts/push-repo.sh๐ง scripts/setup-mcpserver.sh
Configures your local SSH environment to access a remote MCP server:
Pushes your public key
Adds an SSH alias
Prints a sample A-record
chmod +x scripts/setup-mcpserver.sh
./scripts/setup-mcpserver.shโ ๏ธ Edit placeholder values (e.g., IPs, usernames, repo URLs) before executing.
๐ค Contributions
Feel free to fork this repository, submit issues, or create pull requests.
๐ License
This project is licensed under the MIT License.
This server cannot be installed
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/chuckwilliams37/mcp-server-docker'
If you have feedback or need assistance with the MCP directory API, please join our Discord server