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>
22 lines
484 B
Bash
Executable File
22 lines
484 B
Bash
Executable File
#!/bin/bash
|
|
# Health check script for Gitea MCP Remote
|
|
#
|
|
# Used by Docker healthcheck and monitoring systems.
|
|
# Returns exit code 0 if healthy, 1 if unhealthy.
|
|
|
|
set -e
|
|
|
|
HOST="${HTTP_HOST:-localhost}"
|
|
PORT="${HTTP_PORT:-8080}"
|
|
ENDPOINT="http://${HOST}:${PORT}/health"
|
|
|
|
# Make request and check response
|
|
response=$(curl -sf "$ENDPOINT" 2>/dev/null) || exit 1
|
|
|
|
# Verify JSON response contains status: ok
|
|
if echo "$response" | grep -q '"status".*"ok"'; then
|
|
exit 0
|
|
else
|
|
exit 1
|
|
fi
|