Overview
Docker deployment provides a containerized, production-ready environment for the Secure MCP Gateway. The included Docker Compose stack bundles the gateway with a complete observability platform.Prerequisites
- Docker: 20.10 or higher
- Docker Compose: v2.0 or higher
- Git (for cloning the repository)
Verify Docker Installation
Quick Start
1
Build Docker Image
Build the gateway image from the repository:
Build time: ~2-5 minutes depending on your machine. The image includes Python 3.12, Node.js 22.x, and all gateway dependencies.
2
Generate Configuration
Generate the Docker-specific config file:This creates:
- macOS/Linux:
~/.enkrypt/docker/enkrypt_mcp_config.json - Windows:
%USERPROFILE%\.enkrypt\docker\enkrypt_mcp_config.json
3
Install for Claude Desktop
Register the Docker gateway with Claude Desktop:
4
Run Gateway Container
Start the gateway in detached mode:
Replace
<your_gateway_key>, <your_project_id>, and <your_user_id> with values from your generated config file.Docker Compose Deployment
For production deployments, use Docker Compose to deploy the gateway with the complete observability stack.Observability Stack Components
Theinfra/docker-compose.yml includes:
OpenTelemetry Collector
Receives OTLP traces, metrics, and logs from gateway
Jaeger
Distributed tracing visualization (port 16686)
Loki
Log aggregation and storage (port 3100)
Prometheus
Metrics storage and querying (port 9090)
Grafana
Unified dashboards for metrics, logs, traces (port 3000)
Docker Compose Configuration
infra/docker-compose.yml
Prometheus Configuration
infra/prometheus/prometheus.yml
Launch Observability Stack
Access Dashboards
Once the stack is running:Grafana
URL: http://localhost:3000Auth: Anonymous (Admin role)View unified dashboards with metrics, logs, and traces
Jaeger
URL: http://localhost:16686Search and analyze distributed traces
Prometheus
URL: http://localhost:9090Query metrics and view targets
Loki
URL: http://localhost:3100Query logs via API or Grafana
Dockerfile Breakdown
The gateway Dockerfile is a multi-runtime environment:Image Features
Python 3.12 Environment
Python 3.12 Environment
- pip: Standard package installer
- uv: Fast Rust-based package installer (10-100x faster)
- pipx: Isolated Python app installations
- Supports Python-based MCP servers
Node.js 22.x LTS
Node.js 22.x LTS
- npm: Package manager
- npx: Package executor
- Supports JavaScript/TypeScript MCP servers (e.g., GitHub MCP)
Build Tools
Build Tools
- gcc, g++, make for compiling native dependencies
- Python development headers
- SSL, SQLite, readline libraries
Utilities
Utilities
- Git: Repository operations
- jq/yq: JSON/YAML processing
- curl/wget: HTTP downloads
- ssh: Secure remote access
- zip/tar: Archive handling
Claude Desktop Configuration
After Docker installation, your Claude config will look like:claude_desktop_config.json
The
MCP_TRANSPORT=stdio environment variable enables stdio communication mode for Claude Desktop integration.Environment Variables
Key environment variables for Docker deployment:Volumes
Mount these volumes for persistence:Networking
Exposed Ports
- 8000: Gateway MCP server (streamable HTTP)
- 8001: FastAPI REST API (if enabled)
Docker Network
The Compose stack creates a bridge network for inter-service communication:Health Checks
Monitoring Gateway Logs
Troubleshooting
Container Won’t Start
Port Conflicts
Volume Permissions
Observability Stack Issues
Updating
Production Considerations
Use External Cache
Deploy Redis/KeyDB for distributed caching across multiple gateway instances
Enable TLS
Configure TLS certificates for secure communication with OTLP collector
Resource Limits
Set memory and CPU limits:
Persistent Storage
Use named volumes for Prometheus, Loki, and Grafana data persistence
Next Steps
Deployment Patterns
Learn about production deployment architectures
External Cache Setup
Configure Redis/KeyDB for distributed caching
Monitoring Guide
Deep dive into metrics, traces, and logs
CLI Commands
Manage Docker deployment with CLI