Repository navigation
feat(doctor): diagnose kubeconfig validity, port collisions, and stale sockets - #121
Conversation
Codex Review Summary: ❌ FailedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Thanks for tackling #111 — the kubeconfig YAML/loopback check and the Windows 8 MiB main-thread stack fix in
|
774d22f to
2a38a7f
Compare
|
Thanks @zeekay for the detailed review! Rebased cleanly onto
Verified on both Windows and Linux (WSL2): |
…e sockets Signed-off-by: Trần Hoàng Tú <[email protected]>
…ost.rs, and check control.sock & hanzod
2a38a7f to
145019d
Compare
|
Thanks @tranhoangtu-it for addressing every review item cleanly! Verified |
Closes #111
/claim #111
Summary
hanzo doctorinsrc/commands/doctor.rs:diagnose_kubeconfig_path): Checks~/.kube/hanzo.yamlandcommands::up::kubeconfig_path()when present, catching empty/unreadable/malformed YAML, missingclusters/contexts/users/server, and unreachable loopback endpoints, and printing exactrm -f <path> && hanzo start/hanzo startrecovery commands.diagnose_port_collisions): Probes127.0.0.1on ports8080(Hanzo Cloud),9090(Metrics / Prometheus),1234(Hanzo Engine), and8000(IAM / Gateway), skipping ports owned by active local Hanzo services (local_engine_healthy(),local_kube_client().cloud_replicas()) and printing OS-specific one-line inspect/free commands (lsof/killon Unix,netstat -ano | findstr :<port>on Windows).diagnose_runtime_sockets): Inspectshanzod.zap.sock(commands::host::data_dir()),~/.hanzo/up/{vm,supervisor}.sock, and~/.hanzo/vm/hanzo-vm.sockalongside companion.pidfiles viacommands::vm::alive, flagging orphaned sockets withrm -f <socket> && hanzo start.src/main.rs(#[cfg(windows)]8 MiB main-thread & tokio worker stack trampoline) and#[cfg(not(unix))]type annotation insrc/commands/up/diagnose.rs.hanzo doctorchecks and checked ports inREADME.md.Reproducible Verification