fix(autostart): run from repo root + visible console at logon

autostart-run.bat did 'cd /d %~dp0' -> scripts/, but web-vnc.exe/webvnc.conf/
go.mod live in the repo root, so the binary was never found and web-vnc never
started after reboot. Now it cd's to %~dp0.. (repo root).

The task was ONSTART/RU SYSTEM (session 0) so it could not show a window, making
failures invisible. install-autostart.bat now registers ONLOGON /RL HIGHEST as the
current user -> a visible console opens at logon. autostart-run.bat sets a window
title, prints status, stays open while web-vnc serves, and pauses on fatal errors
(no binary / no webvnc.conf) so the reason is visible. Docs updated.
This commit is contained in:
Codex
2026-08-06 01:09:47 +03:00
parent f315618bfc
commit 02fefa1e4e
5 changed files with 98 additions and 43 deletions
+1 -1
View File
@@ -9,7 +9,7 @@ REM
REM It first checks whether web-vnc.exe is actually running:
REM - running -> stop the task (schtasks /End) and start it again;
REM - not running -> just start it (no /End).
REM Requires administrator rights (the task runs as SYSTEM), so it
REM Requires administrator rights (the task was created elevated), so it
REM auto-elevates. Called from set-password.bat, or run manually.
REM ============================================================
cd /d "%~dp0"