Fix Windows install start: writable runtime logs and robust Postgres bootstrap.
Some checks failed
Release Windows / build (push) Has been cancelled

API logs go under ProgramData; first-run verifies CREATE ROLE/DATABASE and login.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
oliver 2026-10-07 11:22:01 +08:00
parent ca97a2a597
commit 86dfd41f44
7 changed files with 64 additions and 33 deletions

View file

@ -9,7 +9,13 @@
$ErrorActionPreference = "Continue"
$useForce = if ($NoForce) { $false } else { [bool]$Force }
$runDir = Join-Path $PSScriptRoot ".run"
if ($env:NETX_RUN_DIR) {
$runDir = $env:NETX_RUN_DIR
} elseif ($env:NETX_SCHEDULER_HEARTBEAT_PATH) {
$runDir = Split-Path -Parent ($env:NETX_SCHEDULER_HEARTBEAT_PATH -replace '/', '\')
} else {
$runDir = Join-Path $PSScriptRoot ".run"
}
$pidFile = Join-Path $runDir "netx.pid"
$workerPidFile = Join-Path $runDir "worker.pid"
$webPidFile = Join-Path $runDir "web.pid"