Add Docker scripts and validation tests for Zen MCP Server

- Created build.sh script for building the Docker image with environment variable checks.
- Added deploy.sh script for deploying the Zen MCP Server with health checks and logging.
- Implemented healthcheck.py to verify server process, Python imports, log directory, and environment variables.
- Developed comprehensive tests for Docker configuration, environment validation, and integration with MCP.
- Included performance tests for Docker image size and startup time.
- Added validation script tests to ensure proper Docker and MCP setup.
This commit is contained in:
OhMyApps
2025-06-25 16:00:48 +02:00
parent 8b7620b262
commit 2de9839096
11 changed files with 1820 additions and 0 deletions

74
.env.docker.example Normal file
View File

@@ -0,0 +1,74 @@
# ===========================================
# Zen MCP Server - Docker Environment Configuration
# ===========================================
# Default AI Model
# Options: "auto", "gemini-2.5-pro", "gpt-4", etc.
DEFAULT_MODEL=auto
# ===========================================
# API Keys (Required - at least one)
# ===========================================
# Google AI (Gemini models)
GEMINI_API_KEY=your_gemini_api_key_here
# OpenAI (GPT models)
OPENAI_API_KEY=your_openai_api_key_here
# Anthropic (Claude models - if needed)
ANTHROPIC_API_KEY=your_anthropic_api_key_here
# xAI (Grok models - if needed)
XAI_API_KEY=your_xai_api_key_here
# DIAL (unified enterprise access)
DIAL_API_KEY=your_dial_api_key_here
DIAL_API_HOST=https://core.dialx.ai
DIAL_API_VERSION=2025-01-01-preview
# OpenRouter (unified cloud access)
OPENROUTER_API_KEY=your_openrouter_api_key_here
# Custom API endpoints (Ollama, vLLM, LM Studio, etc.)
CUSTOM_API_URL=http://localhost:11434/v1
CUSTOM_API_KEY=
CUSTOM_MODEL_NAME=llama3.2
# ===========================================
# Logging Configuration
# ===========================================
# Log level: DEBUG, INFO, WARNING, ERROR, CRITICAL
LOG_LEVEL=INFO
# Maximum log file size
LOG_MAX_SIZE=10MB
# Number of backup log files to keep
LOG_BACKUP_COUNT=5
# ===========================================
# Advanced Configuration
# ===========================================
# Default thinking mode for ThinkDeep tool
# Options: minimal, low, medium, high, max
DEFAULT_THINKING_MODE_THINKDEEP=high
# Disabled tools (comma-separated list)
# Example: DISABLED_TOOLS=testgen,secaudit
DISABLED_TOOLS=
# Maximum MCP output tokens
MAX_MCP_OUTPUT_TOKENS=
# ===========================================
# Docker Configuration
# ===========================================
# Container name
COMPOSE_PROJECT_NAME=zen-mcp
# Timezone
TZ=UTC