Open KaivenBugwadia opened 3 months ago
As part of my application for the LFX mentorship project I have implemented a sample command.
This PR adds the health sub-command to display server and component statuses.
health
./harbor health
Status: healthy ┌─────────────────────────────────────────────────────────────────────────┐ │ Component Name Status Error Message │ │ ─────────────────────────────────────────────────────────────────────── │ │ core healthy │ │ database healthy │ │ jobservice healthy │ │ portal healthy │ │ redis healthy │ │ registry healthy │ │ registryctl healthy │ │ trivy healthy │ └─────────────────────────────────────────────────────────────────────────┘
I also implemented the YAML output format, which was added for other commands by PR https://github.com/goharbor/harbor-cli/pull/74.
./harbor health -o yaml
components: - error: "" name: core status: healthy - error: "" name: database status: healthy - error: "" name: jobservice status: healthy - error: "" name: portal status: healthy - error: "" name: redis status: healthy - error: "" name: registry status: healthy - error: "" name: registryctl status: healthy - error: "" name: trivy status: healthy status: healthy
Here is a GIF of the command in the CLI
As part of my application for the LFX mentorship project I have implemented a sample command.
This PR adds the
health
sub-command to display server and component statuses.I also implemented the YAML output format, which was added for other commands by PR https://github.com/goharbor/harbor-cli/pull/74.
Here is a GIF of the command in the CLI