@echo off
setlocal
cd /d "%~dp0"
title ComputePool Worker
echo.
echo Starting ComputePool Worker...
echo Local dashboard: http://127.0.0.1:7788/
echo.
if exist "%~dp0dist\ComputePool-Worker.exe" (
  start "" "%~dp0dist\ComputePool-Worker.exe"
) else (
  start "" powershell.exe -NoProfile -ExecutionPolicy Bypass -File "%~dp0start-local-worker.ps1"
)
timeout /t 2 >nul
start "" "http://127.0.0.1:7788/"
