generated from personal-projects/leo-claude-mktplace
Issue #25 - Docker multi-service infrastructure: - Create docker/Dockerfile with multi-stage build, git support, port 8080 - Create docker/docker-compose.yml with app + Caddy services - Create docker/Caddyfile for HTTPS termination and reverse proxy - Create docker/.env.example with configuration template Issue #26 - Startup scripts and tests: - Create scripts/start.sh for production startup with env validation - Create scripts/healthcheck.sh for Docker health checks - Add health endpoint tests to test_mcp_endpoints.py - Fix middleware order (HealthCheckBypass must wrap BearerAuth) - Fix pyproject.toml testpaths to use 'tests' directory - Update test_config.py for new defaults (0.0.0.0:8080) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
47 lines
1.0 KiB
Caddyfile
47 lines
1.0 KiB
Caddyfile
# Caddy reverse proxy configuration for Gitea MCP Remote
|
|
#
|
|
# This configuration provides:
|
|
# - HTTPS termination with automatic certificates
|
|
# - Reverse proxy to the Python MCP server
|
|
# - Health check endpoint passthrough
|
|
# - MCP protocol endpoint routing
|
|
{
|
|
# Global options
|
|
email admin@example.com
|
|
|
|
# For local development, disable HTTPS redirect
|
|
# auto_https off
|
|
}
|
|
|
|
# Default site - adjust domain as needed
|
|
:443, :80 {
|
|
# Health check endpoint - no authentication
|
|
handle /health {
|
|
reverse_proxy app:8080
|
|
}
|
|
|
|
# MCP protocol endpoint
|
|
handle /mcp {
|
|
reverse_proxy app:8080 {
|
|
# Pass through headers for MCP protocol
|
|
header_up X-Forwarded-Proto {scheme}
|
|
header_up X-Real-IP {remote_host}
|
|
|
|
# Ensure proper content type handling
|
|
flush_interval -1
|
|
}
|
|
}
|
|
|
|
# Fallback - proxy all other requests
|
|
handle {
|
|
reverse_proxy app:8080
|
|
}
|
|
|
|
# Logging
|
|
log {
|
|
output stdout
|
|
format console
|
|
}
|
|
}
|