Skip to content

[slopfix] fix(self-host): repair dev compose generation, kitchen-sink serverful runner, and postgres/udb bootstrap - #5340

Open
MasterPtato wants to merge 1 commit into
stack/slop-claude-opus-4-8-high-feat-universaldb-graceful-postgres-leader-handoff-on-shutdown-mvxpzxslfrom
stack/slopfix-fix-self-host-repair-dev-compose-generation-kitchen-sink-serverful-runner-and-postgres-udb-bootstrap-wpvkrymu
Open

[slopfix] fix(self-host): repair dev compose generation, kitchen-sink serverful runner, and postgres/udb bootstrap#5340
MasterPtato wants to merge 1 commit into
stack/slop-claude-opus-4-8-high-feat-universaldb-graceful-postgres-leader-handoff-on-shutdown-mvxpzxslfrom
stack/slopfix-fix-self-host-repair-dev-compose-generation-kitchen-sink-serverful-runner-and-postgres-udb-bootstrap-wpvkrymu

Conversation

@MasterPtato

@MasterPtato MasterPtato commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@MasterPtato

MasterPtato commented Jun 25, 2026

Copy link
Copy Markdown
Contributor Author

Stack for rivet-dev/rivet

Get stack: forklift get 5340
Push local edits: forklift submit
Merge when ready: forklift merge 5340

change wpvkrymu

@claude

claude Bot commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

Review

Reviewed the diff (self-host compose regeneration/relocation, kitchen-sink Dockerfile, Prometheus registry namespace, runner-config bootstrap). Overall this is a solid "repair" PR — I traced the config removals against the Rust defaults and the metric-name change against the Grafana dashboard JSON, and both check out as correct fixes rather than regressions. Two doc/config drift issues are left behind by the directory move, though.

Issues found

1. Root CLAUDE.md "Docker dev environment" section now points at a path that no longer exists.
This PR moves the generated compose output from self-host/compose/dev* to self-host/dev* (confirmed via the PR's own renames and self-host/compose/template/src/main.ts's outputDir = path.join(__dirname, "../../../", templateName), which resolves to self-host/<name>, not self-host/compose/<name>). CLAUDE.md (repo root, lines 69-76) still says:

cd self-host/compose/dev
docker-compose up -d

and

- Do not edit `self-host/compose/dev*` configs directly. Edit the template in `self-host/compose/template/` and rerun...

Both are stale now — cd self-host/compose/dev will fail, and the caution note should say self-host/dev*. Since this file is load-bearing instructions for future agents/contributors, it's worth fixing in this PR (or a fast follow) rather than leaving it to drift.

2. Root .gitattributes linguist-generated patterns still target the old paths.
Lines 30-34 of .gitattributes mark self-host/compose/dev/**, self-host/compose/dev-host/**, etc. as linguist-generated=true. Since those directories moved to self-host/dev/**, self-host/dev-host/**, etc., these patterns no longer match anything, so GitHub will stop collapsing the generated compose/Grafana/vector configs in diffs and will start counting them in language stats. Should be updated to the new self-host/dev*/** paths in the same change.

Things that look correct (verified, not just assumed)

  • engine/packages/metrics/src/registry.rs: adding the "rivet" namespace to the Prometheus registry looks like a genuine fix, not a breaking rename — the checked-in Grafana dashboards (e.g. dashboards/api.json) already query rivet_api_request_duration_bucket, etc., while the Rust metric is registered as bare "api_request_duration" (engine/packages/api-builder/src/metrics.rs). Before this change the exposed metric name and the dashboard queries didn't match; this fixes that. I didn't find any metric already registered with an explicit rivet_ prefix, so there's no double-prefixing risk.
  • Removed guard.port, api_peer.port, cache.driver, clickhouse.secure from the generated config.jsonc files match the Rust defaults exactly (GUARD: u16 = 6420, API_PEER: u16 = 6421, CacheDriver::InMemory, secure: bool with #[serde(default)]false), so this is a safe simplification, not a functional change.
  • The new runner-config-init one-shot service and its curl retry loop look correct: valid shell quoting, correctly gated behind service_healthy/service_completed_successfully, and the RIVET_KITCHEN_SINK_MODE/RIVET_POOL env vars it feeds the runner are consumed by the existing kitchen-sink example code and rivetkit's env-vars.ts.
  • Postgres max_connections=500 and mounting the volume at the /var/lib/postgresql parent (rather than /var/lib/postgresql/data) are reasonable dev-only changes; no PGDATA override is introduced so Postgres will still use .../data inside the volume.

Minor / non-blocking

  • self-host/compose/template/src/services/edge/runner.ts is now an empty function kept only for its comment — pre-existing pattern, not introduced here, but worth eventually just inlining the comment at the call site if generateRunner never grows real logic.
  • The runner-config-init script hardcodes 6420 and the Bearer dev admin token; consistent with the rest of this dev-only template (which already hardcodes admin_token: "dev" and 6420 elsewhere), so not a new issue, just flagging since it's a fresh piece of shell.

No test coverage changes are included, which is expected/fine for compose-template and docs plumbing like this — nothing here is unit-testable Rust/TS logic beyond what's already covered.

@NathanFlurry NathanFlurry changed the title [slopfix] fix(self-host): repair dev compose generation, kitchen-sink serverful runner, and postgres/udb bootstrap fix(self-host): repair dev compose generation, kitchen-sink serverful runner, and postgres/udb bootstrap Jun 26, 2026
@MasterPtato MasterPtato changed the title fix(self-host): repair dev compose generation, kitchen-sink serverful runner, and postgres/udb bootstrap [slopfix] fix(self-host): repair dev compose generation, kitchen-sink serverful runner, and postgres/udb bootstrap Jun 29, 2026
@MasterPtato
MasterPtato changed the base branch from stack/slop-claude-opus-4-8-high-feat-universaldb-graceful-postgres-leader-handoff-on-shutdown-mvxpzxsl to main August 7, 2026 00:39
… serverful runner, and postgres/udb bootstrap
@MasterPtato
MasterPtato force-pushed the stack/slopfix-fix-self-host-repair-dev-compose-generation-kitchen-sink-serverful-runner-and-postgres-udb-bootstrap-wpvkrymu branch from f46a359 to dce315d Compare August 7, 2026 01:27
@MasterPtato
MasterPtato changed the base branch from main to stack/slop-claude-opus-4-8-high-feat-universaldb-graceful-postgres-leader-handoff-on-shutdown-mvxpzxsl August 7, 2026 01:27
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.

1 participant