claudify CLI should auto-reattach on gateway restart #2
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
When the gateway pod is rolled (helm upgrade, crash, etc.), in-flight SSH attach connections die. The CLI currently prints the ssh error and exits. For any real use, the CLI should:
GET /sessions/<name>untilphase == RunningandpodNameis set, with a bounded backoff.sshwith the same session name.--retry-timeout 60sflag?).Tricky bits:
exec()on Linux replaces the process, so a retry loop must either notexecand insteadspawn+wait, or use a wrapper shell loop. Spawning is probably cleaner; lose the 'ssh fully owns the PTY' property but gain the ability to restart.client/mod.rs. The attach path doesn't use that; needs similar treatment.Required for
Not a v0.1.0 blocker. Users can manually
claudify attach <same name>after a gateway roll, which works because the SSH subsystem+session resolution is idempotent.Implementation sketch
Replace the current
cmd.exec()incrates/cli/src/cmd/attach.rswith a retry loop: