Fix wehago compare loading and matching workflow

This commit is contained in:
b17301
2026-05-08 23:38:16 +09:00
parent 37f422b493
commit 99137e5f97
5 changed files with 5925 additions and 547 deletions
+14 -1
View File
@@ -4,6 +4,7 @@ set -euo pipefail
cd "$(dirname "$0")/.."
PORT="${1:-${INTRANET_PORT:-8010}}"
HEALTH_URL="http://127.0.0.1:${PORT}/health"
if [ ! -x ".venv/bin/python" ]; then
echo "가상환경이 없습니다. 먼저 아래를 실행하세요."
@@ -13,7 +14,19 @@ if [ ! -x ".venv/bin/python" ]; then
exit 1
fi
export INTRANET_AUTO_RELOAD="${INTRANET_AUTO_RELOAD:-1}"
if curl -fsS --max-time 2 "$HEALTH_URL" >/dev/null 2>&1; then
echo "이미 실행 중입니다: $HEALTH_URL"
exit 0
fi
if ss -ltn "( sport = :${PORT} )" | tail -n +2 | grep -q .; then
echo "포트 ${PORT} 는 이미 다른 프로세스가 사용 중입니다."
echo "기존 서버가 멈춘 상태라면 먼저 종료한 뒤 다시 실행하세요."
ss -ltnp "( sport = :${PORT} )" || true
exit 1
fi
export INTRANET_AUTO_RELOAD="${INTRANET_AUTO_RELOAD:-0}"
export INTRANET_PORT="$PORT"
exec ./.venv/bin/python main.py