docker-compose.example.yml•1.21 kB
version: '3.8'
services:
mcp-server:
build: .
ports:
- "8000:8000"
environment:
- ODOO_URL=https://your-odoo-instance.com
- ODOO_DB=your_database_name
- ODOO_USERNAME=your_username@example.com
- ODOO_API_KEY=your_api_key_here
- MCP_HOST=0.0.0.0
- MCP_PORT=8000
- MCP_DEBUG=false
- MCP_LOG_LEVEL=INFO
- CACHE_ENABLED=true
- CACHE_TTL=300
- CACHE_MAX_SIZE=1000
volumes:
- ./logs:/app/logs
restart: unless-stopped
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8000/health"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
# Optional: Redis for session management and caching
redis:
image: redis:7-alpine
ports:
- "6379:6379"
volumes:
- redis_data:/data
restart: unless-stopped
profiles:
- redis
# Optional: Nginx reverse proxy
nginx:
image: nginx:alpine
ports:
- "80:80"
- "443:443"
volumes:
- ./nginx.conf:/etc/nginx/nginx.conf:ro
- ./ssl:/etc/nginx/ssl:ro
depends_on:
- mcp-server
restart: unless-stopped
profiles:
- proxy
volumes:
redis_data: