Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Return non-zero on "microk8s status" when service is stopped #3975

Closed

Conversation

rsalinas
Copy link

@rsalinas rsalinas commented May 17, 2023

Summary

microk8s status returns 0 when the server is down.

$ microk8s status --yaml ; echo $?
microk8s is not running, try microk8s start
0

What Should Happen Instead?
I would expect it to return non-zero, so that I don't need to search for text in the output.

This also complicates my life when trying to directly parse its output as yaml.
Closes #3974

Changes

It returns 1 instead of 0 when the server is down.

Testing

I DID NOT TEST MY CHANGES.
Please someone adopt this tiny change and test it for me :)

Possible Regressions

Checklist

  • Read the contributions page.
  • Submitted the CLA form, if you are a first time contributor.
  • The introduced changes are covered by unit and/or integration tests.

Notes

Copy link

stale bot commented Sep 7, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the inactive label Sep 7, 2024
@stale stale bot closed this Oct 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

"microk8s status" exits with zero return code when server is down
1 participant