Conversation
Displays overall system status and per-group/component breakdown from the API's /status endpoint, with color-coded output matching the dashboard indicator.
Added error handling to the `runStatus` function to log an error message and return an error when the response status code from the Kernel API is not in the 2xx range. This improves user feedback when the API is unreachable.
…o phani/kernel-status-cli
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 2 potential issues.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
masnwilliams
left a comment
There was a problem hiding this comment.
cmd/status.go line 43 — nit: getBaseURL() + defaultBaseURL is duplicated from cmd/deploy.go — consider extracting to a shared helper so they stay in sync. also note that KERNEL_BASE_URL isn't actually set anywhere (no .env), so this always hits api.onkernel.com — worth a comment clarifying it's for internal dev/staging only.
cmd/status.go line 57 — nit: double error output — pterm.Error.Println prints a user-facing message, then the returned error gets printed by cobra too. pick one or the other (same on line 63).
… output - Move base URL resolution to shared util.GetBaseURL() so status.go and deploy.go stay in sync. - Fix status command returning both pterm error and fmt.Errorf (double output); use pterm + return nil to match codebase convention. - Run gofmt to fix pre-existing indentation in deploy.go.
Good catch - extracted to util.GetBaseURL() in pkg/util/client.go, both status.go and deploy.go use it now. Also fixed the double error output to pterm.Error + return nil. |
Displays overall system status and per-group/component breakdown from the API's /status endpoint, with color-coded output matching the dashboard indicator.
Note
Low Risk
Low risk: adds a read-only status check command and small refactors to centralize base URL selection, with minimal impact on existing deploy flows.
Overview
Adds a new unauthenticated
kernel statuscommand that fetches/statusfrom the API and prints a color-coded service/group/component health summary (or pretty JSON via--output json).Centralizes API base URL selection in
util.GetBaseURL()and updates GitHub deploy and the new status command to use it; also registersstatusinrootCmdand exempts it from auth checks.Written by Cursor Bugbot for commit 95e2273. This will update automatically on new commits. Configure here.