Files
corrosion-admin-panel/corrosion-host-agent
Vantz Stockwell 702de24e28
Some checks failed
CI / backend-types (push) Successful in 10s
CI / frontend-build (push) Successful in 15s
CI / agent-tests (push) Successful in 43s
Build Host Agent (Rust) / build (push) Failing after 1m33s
CI / integration (push) Successful in 22s
fix(ci): fetch minisign static binary (not in bullseye apt); bump alpha.7
alpha.6 signing failed: 'E: Unable to locate package minisign' —
minisign isn't packaged for node:20-bullseye. Download the official
static linux binary instead. Forward to alpha.7 (alpha.6 published
nothing).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-06-11 20:18:08 -04:00
..

Corrosion Host Agent

Rust rewrite of the Go companion agent (companion-agent/, retained as the behavior reference until parity). One agent per machine supervises every game instance on that host — Rust, Conan Exiles, Soulmask, Dune: Awakening.

Status — Phase 0

  • Multi-instance TOML config + env overrides (CORROSION_LICENSE_ID, CORROSION_NATS_URL, CORROSION_NATS_TOKEN)
  • NATS connection (infinite reconnect, capped backoff, 30s ping, offline send-buffering, tls:// support)
  • Host heartbeat with real telemetry (sysinfo: CPU, memory, disks) — no fabricated values
  • Connectivity prober (outbound TCP, periodic + on-demand)
  • Host command channel (ping, probe, sysinfo)
  • Graceful shutdown (cancellation token, going-offline beacon, NATS flush)
  • Phase 1a: process supervision — per-instance start/stop/restart/status over {instance}.cmd request-reply, push state events on {instance}.status, crash detection with exit codes, live state in heartbeats (integration-tested with real processes + live-NATS contract test)
  • Phase 1b: RCON trait (WebRCON rust / TCP conan+soulmask), SteamCMD, jailed file manager
  • Phase 2: Dune Docker adapter (compose lifecycle, RabbitMQ bus, Postgres admin)
  • Phase 3a: SIGNED self-update — minisign-verified download+swap+relaunch (NATS update func); embedded public key; CI signs releases
  • Phase 3b: service install (systemd/SCM), PID adoption

Build

cargo build --release                                    # native
cargo build --release --target x86_64-unknown-linux-gnu  # linux deploy target
cargo build --release --target x86_64-pc-windows-msvc    # windows (cargo-xwin on non-Windows)

Run

corrosion-host-agent --config ./agent.toml         # foreground
corrosion-host-agent --config ./agent.toml check   # validate config only
corrosion-host-agent version                       # semver + git hash + build ts