Skip to content

docs(kalshi): document Edge Connect teardown in the runbook - #200

Draft
ben-dz wants to merge 1 commit into
mainfrom
bdz/kalshi-runbook-teardown
Draft

docs(kalshi): document Edge Connect teardown in the runbook#200
ben-dz wants to merge 1 commit into
mainfrom
bdz/kalshi-runbook-teardown

Conversation

@ben-dz

@ben-dz ben-dz commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

The Kalshi runbook ends at "Confirm data path" with no removal path, so the only uninstall guidance for Edge Connect lives in the bridge repo's README. An agent driving this runbook via get_onboarding_runbook has nothing to offer a user who asks how to undo it.

Adds a ## Teardown section and one gotcha.

The part worth reviewing is the correctness claim, not the prose. docker stop is the uninstall: the entrypoint stays PID 1 specifically so its TERM trap can run a bounded doublezero disconnect while the daemon is still up, and the installer sets --stop-timeout 60 to give it room. So a manual doublezero disconnect first is redundant — but docker rm -f or docker kill bypasses the trap and orphans the onchain session and doublezero1 in the host netns. That is gotcha 8 ("Stale doublezero1") arriving self-inflicted, and it was documented nowhere user-facing; connect.sh warns about it only in its own reinstall path. The verification step uses ip link show doublezero1 rather than doublezero status, since the latter is only reachable through docker exec and the container is gone by then.

Sources: docker-entrypoint.sh (the trap and its SIGNALED/dz_connected guards), scripts/connect.sh (--stop-timeout 60, and the orphaned-iface warning it emits after a failed graceful stop).

Blocker — this page is already truncated

Not introduced here, but it makes this PR ineffective on its own. The MCP fetches runbooks through docsfetch, which hard-cuts every page at MaxPageBytes = 10000. This page is 11,086 bytes on main, so the model already never sees the tail — the cut lands mid-sentence in gotcha 7, dropping gotcha 8, the consumer sketch and See also. The section added here sits past that cut.

It is systemic, not specific to this page. 9 of the 20 MCP-served pages are over the limit: troubleshooting at 21,033 bytes loses 52% of itself, contribute 43%, and kalshi, contribute-operations, geolocation, glossary, setup and multicast-admin are all cut. That is worth its own issue against lake.

So: merge this for the content and the docs site, but the MCP will not serve it until MaxPageBytes is raised or these pages are trimmed. Happy to trim this page under 10,000 in this PR instead if that is the call.

The runbook ends at 'Confirm data path' with no removal path, so the only
uninstall guidance for Edge Connect lives in the bridge repo's README.

Add a Teardown section covering the part that is easy to get wrong: 'docker
stop' is the uninstall, because the entrypoint stays PID 1 so its TERM trap
can run a bounded 'doublezero disconnect' before the daemon goes down. A
'docker rm -f' or 'docker kill' bypasses that trap and orphans the onchain
session and doublezero1 in the host netns.
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