Skip to content

Add opt-in live launcher server directory - #20

Draft
valzargaming wants to merge 7 commits into
mainfrom
codex/live-launcher-directory
Draft

valzargaming wants to merge 7 commits into
mainfrom
codex/live-launcher-directory

Conversation

@valzargaming

@valzargaming valzargaming commented Oct 19, 2026 •

Copy link
Copy Markdown
Member

Summary

  • Build a separate directory-only artifact from a committed minimal Composer lock. The CI matrix installs without scripts/plugins, audits the lock, builds a bounded checksummed archive, verifies it without extraction/execution, and runs the directory suites against the artifact’s own dependencies. The artifact includes patched React HTTP 1.11.1 and no Discord or live application bootstrap.
  • Add an optional isolated directory-only entrypoint for installations where restarting the live bot is unsafe. It binds only 127.0.0.1, has a strict default-empty JSON inventory, exposes no bot controls, and never constructs Civ13/GameServer/Discord. Invalid/empty inventory is checked before dependency autoload; runtime logs expose only controlled startup phases.
  • Add an opt-in, read-only route on the existing ReactPHP service. One HTTPS authority, civ13.com, serves separate provider snapshots through the exact raw queries provider=civ13.com and provider=valzargaming.com. Other query strings, extra/repeated parameters, alternate encodings and other authorities are rejected.
  • Preserve the existing enabled-GameServer mapping and add a separate default-empty, strict five-field status-only inventory. Remote entries never construct or enable GameServer/pers, require no local game directory, accept only the two approved hosts, and cannot carry URLs, IP overrides or lifecycle settings. IDs and host/port pairs are unique across both sources, with a global 32-target cap.
  • Resolve public status-only hosts afresh on every probe. Validate all 1–32 IPv4 A answers against the same conservative public-address policy as the launcher and connect to the validated literal without another lookup. No public IP pins; intentional managed local/private mappings remain supported.
  • Use bounded asynchronous fixed BYOND status queries, three-second total deadlines, non-overlapping sweeps, per-probe freshness, and online-only metadata projection. Zero-player servers remain visible; stale/offline/malformed entries are omitted without losing healthy peers. Private status/account/admin fields are never published.
  • Include shared managed/Unicode/VZG fixtures and offline protocol, endpoint, startup, status-only inventory, DNS/TCP-binding and slow-peer freshness tests on PHP 8.3–8.5.

Validation

  • Exact head 2b85f7c88b1f740a450252c714369a72c7bcc44a: all CI is terminal green; docs publication skipped as expected.
  • PHP 8.3, 8.4 and 8.5 source/entrypoint lint, all four directory suites, CLI pre-autoload rejection/empty-inventory tests and existing bot regressions passed: https://github.com/Valgorithms/Civilizationbot/actions/runs/39317622904
  • PHP 8.3/8.4/8.5 bundle build, audit, artifact verification and artifact-dependency tests passed: https://github.com/Valgorithms/Civilizationbot/actions/runs/39317622909
  • Downloaded PHP 8.4 artifact verified locally: commit 2b85f7c88b1f740a450252c714369a72c7bcc44a, 197 files, 1,331,920 expanded bytes, archive SHA256 921a267f4980fe715910f99b62bddf6399fb088127ac8d2ff44f6c4bb309ec8c. No deployed instance is claimed.
  • PR dependency and local-profile/supervision checks also passed on the exact head (see Checks tab).
  • git diff --check and workflow YAML parsing pass. No local PHP runtime pass is claimed.
  • All three shared fixtures pass the paired launcher's production parser. Managed and Unicode bytes are unchanged; VZG fixture SHA256: ccda85f14b96c78d49d7717baacc46edf9e2e4436c2a08d00f70491d07365d1f.
  • Tests exercise registry-before-HTTP ordering, no GameServer lifecycle effects for status-only inventory, dynamic public DNS/exact-IP TCP binding, partial failures and per-probe freshness. They do not establish production readiness or genuine joins.

Deployment gate

The optional isolated entrypoint requires the pinned directory-only CI artifact and matching archive/manifest verification, or separately reviewed dependency files. The prepared artifact avoids importing or changing the live bot’s vendor tree. Do not bootstrap unknown application-root/untracked autoload files or modify/restart the live bot. See docs/launcher-directory-standalone.md.

This remains a draft. Both configuration options default to empty and no live configuration, endpoint deployment, bot restart, firewall/TLS change, merge or release is included. Only the existing civ13.com HTTPS route is needed; valzargaming.com does not require a new HTTPS service. The selected provider's actual production inventory and ports must be verified before configuration, including the currently disabled checked-in pers entry. A configured empty provider returns 200/empty; an unconfigured provider returns 404; stale/warmup returns 503. Live status and genuine BYOND join acceptance are separate gates. See docs/launcher-directory.md for exact routing and operator requirements.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants