start_checker: browser opens only when service answers 200; clear failure message
This commit is contained in:
1 parent
257c5c286b
commit
7ea639ec1f
1 file changed
+10
-1
@@ -23,5 +23,14 @@ set LT_URL=http://127.0.0.1:8010
|
|||||||
set LLM_BASE_URL=http://127.0.0.1:11434/v1
|
set LLM_BASE_URL=http://127.0.0.1:11434/v1
|
||||||
set LLM_MODEL=qwen3-4b-instruct
|
set LLM_MODEL=qwen3-4b-instruct
|
||||||
start "docchecker" "%PYEXE%" -m uvicorn app:app --host 127.0.0.1 --port 8011
|
start "docchecker" "%PYEXE%" -m uvicorn app:app --host 127.0.0.1 --port 8011
|
||||||
timeout /t 5 /nobreak >nul
|
set "OK="
|
||||||
|
for /l %%i in (1,1,6) do (
|
||||||
|
if not defined OK curl -s --max-time 2 -o nul -w "%%{http_code}" http://127.0.0.1:8011/api/health 2>nul | findstr "200" >nul && set OK=1
|
||||||
|
if not defined OK timeout /t 2 /nobreak >nul
|
||||||
|
)
|
||||||
|
if not defined OK (
|
||||||
|
echo Служба не поднялась за 12 сек — смотри окно docchecker, там причина
|
||||||
|
pause
|
||||||
|
exit /b 1
|
||||||
|
)
|
||||||
start http://127.0.0.1:8011
|
start http://127.0.0.1:8011
|
||||||
Reference in new issue
Block a user