39246-vm/restart.bat
abbashkyt-creator 7d8ce0e322 V0.1
2026-03-14 04:02:22 +03:00

29 lines
709 B
Batchfile

@echo off
REM Ghost Node Auto-Restart Wrapper
REM This script is called by the restart API endpoint
REM It spawns a fresh Python process and exits
setlocal enabledelayedexpansion
REM Get the directory of this script
cd /d "%~dp0"
echo.
echo ========================================
echo Ghost Node Auto-Restart
echo ========================================
echo [Spawn] Starting new process...
echo [Spawn] Command: python worker.py
echo.
REM Spawn the new process in background (detached)
REM This runs completely independently
start "" /B /MIN python worker.py
REM Give it a moment to start
timeout /t 1 /nobreak >nul
REM Exit this wrapper
echo [Spawn] New process spawned. Wrapper exiting.
exit /b 0