Windows combined package 0.2.0 (proto-cuda/windows-app): v4 exes from target-integration, peers = seed then Mac, fresh appdir devnet-v4, one miner and one worker per card with --identities 8, --evm-address (PAYOUT_EVM or derived per vendor from the PC name), voting on (VOTE=0 opts out), --prepare-packs for the hot swap with --exit-on-seed-change as the fallback, --yes on the node, STATUS regex tolerant of the v4 now= segment, version in the dashboard header. Mac app 0.2.0 (packaging/mac): v4 binaries, Metal worker rebuilt for macOS 11, data folder devnet-v4, EVM payout, identities in one process, synced= flag honoured. Seed (infra/seed-nodes): stage-v4.sh builds v4 on the VM as a niced, memory-capped transient service and installs a disabled igneumd-v4 unit with a fresh data dir; switch-v4.sh swaps the units (--back reverses); health.sh reports active-v4. Runbook: docs/plans/cutover-2026-10-04.md. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
67 lines
3.8 KiB
PowerShell
67 lines
3.8 KiB
PowerShell
# Igneum devnet node, Windows launcher: the node only. Started by START-NODE.bat, which sets the settings as environment
|
|
# variables (MAC_NODE, RPC_LISTEN, P2P_LISTEN, APPDIR, UNSYNCED_MINING, EXTRA_ARGS, PLAIN). 3 October 2026.
|
|
# The functions live in igneum-common.ps1; START-IGNEUM.bat runs the same code with the miners in the same window.
|
|
#
|
|
# Starts igneumd.exe --devnet with --appdir, --rpclisten, --listen, one --addpeer per PEER_NODES entry (the seed node and
|
|
# the Mac), --nodnsseed, --disable-upnp, --yes and
|
|
# --nologfiles (the node's output goes to node-<stamp>.log, a new segment per start). The window shows the NODE card
|
|
# (a reading every 5 s while syncing, then every 30 s), a status line goes to the launcher log every 30 s, the logs are
|
|
# uploaded every 60 s, a crash restarts the node after 5 to 60 s, Ctrl+C stops it.
|
|
#
|
|
# Why --addpeer and not --connect: in igneumd (kaspad/src/daemon.rs) --connect sets the inbound limit to 0 and skips
|
|
# outbound peers, so the Mac could never dial this PC. --addpeer keeps the Mac as a permanent peer (retried with a
|
|
# backoff of up to 8 minutes, components/connectionmanager/src/lib.rs) and leaves the listener open for the Mac.
|
|
|
|
$launcherName = 'node-launcher'
|
|
. (Join-Path $PSScriptRoot 'igneum-common.ps1')
|
|
|
|
$script:title = 'Igneum: node only'
|
|
Set-NodeTarget $rpcHost $rpcPort
|
|
Log "igneum node launcher $packageVersion ($chainVersion) on $machine (run $stamp): peers $($peerNodes -join ' '), RPC $rpcListen, p2p $p2pListen, appdir $appDir, unsynced mining $(if ($unsyncedMining) { 'on' } else { 'off' })"
|
|
|
|
if (-not (Test-Path $nodeExe)) { Log 'igneumd.exe is missing from this folder. Extract the whole zip first.'; exit 1 }
|
|
$ver = ''
|
|
try { $ver = (& $nodeExe --version 2>&1 | Select-Object -First 1) } catch { $ver = "could not run igneumd.exe: $_" }
|
|
Log "node binary: $nodeExe ($ver)"
|
|
if (-not (Test-Path $miner)) { Log 'igneum-miner.exe is not in this folder: the card will only say whether the node process is alive' }
|
|
|
|
$ports = Test-NodePorts
|
|
if ($ports -eq 'external') { Log "a node already answers on ${rpcHost}:${rpcPort}. Is another START-NODE or START-IGNEUM window open? Close it first."; exit 1 }
|
|
if ($ports -ne 'free') { Log $ports; exit 1 }
|
|
|
|
if (Test-TcpPort $macHost ([int]$macPort) 1500) { Log "the Mac node answers on $macNode" } else { Log "the Mac node at $macNode does not answer right now; igneumd will keep retrying (backoff up to 8 minutes)" }
|
|
Log "If Windows Firewall asks about igneumd.exe: tick Private networks and click Allow access (the Mac node dials this PC on port $p2pPort). If you clicked Cancel once, run ALLOW-FIREWALL.bat."
|
|
New-Item -ItemType Directory -Force -Path $appDir | Out-Null
|
|
|
|
$script:node.on = $true
|
|
$script:node.managed = $true
|
|
Start-Node
|
|
Start-Sleep -Seconds 3
|
|
if ($script:node.proc.HasExited) {
|
|
Log "igneumd exited at once with code $($script:node.proc.ExitCode). Last lines:"
|
|
foreach ($l in (Get-TailLines $script:node.err 8)) { Log " stderr: $l" }
|
|
foreach ($l in (Get-TailLines $script:node.log 8)) { Log " stdout: $l" }
|
|
Log "Nothing to restart. Fix the cause above (a wrong --appdir, a port in use, a database from an older build that needs deleting: $appDir) and start again."
|
|
exit 1
|
|
}
|
|
foreach ($l in (Get-TailLines $script:node.log 3)) { Log " node: $l" }
|
|
|
|
Enable-KeepAwake 'the node runs'
|
|
[Console]::TreatControlCAsInput = $true
|
|
Log "running. Press Ctrl+C to stop. The node's full output is in $($script:node.log)"
|
|
Start-ChainSample
|
|
Start-Dashboard
|
|
$stop = $false
|
|
$exitCode = 0
|
|
try {
|
|
while (-not $stop) {
|
|
Start-Sleep -Milliseconds 500
|
|
if (Test-StopKey) { $stop = $true; break }
|
|
Invoke-CommonStep
|
|
if ($script:node.gaveUp) { break }
|
|
}
|
|
} finally {
|
|
if ($script:node.gaveUp) { $exitCode = 1 }
|
|
Stop-Everything $(if ($stop) { 'Ctrl+C: stopping' } else { '' })
|
|
}
|
|
exit $exitCode
|