-
Notifications
You must be signed in to change notification settings - Fork 243
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
fix (machine) : crc daemon /status
api should return correct preset value for okd
cluster (#4478)
#4480
Conversation
Hi @rohanKanojia. Thanks for your PR. I'm waiting for a crc-org member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
/ok-to-test |
1cb8203
to
157b1a0
Compare
… value for `okd` cluster (crc-org#4478) + Refactor `Status()` method to move ClusterStatusResult object creation logic to a separate method for easier testing + Add case for OKD preset while setting preset value in cluster preset Signed-off-by: Rohan Kumar <[email protected]>
157b1a0
to
691b143
Compare
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: anjannath The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@rohanKanojia: The following tests failed, say
Full PR test history. Your PR dashboard. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
Fix #4478
Relates to: Issue #4478 #4479
Solution/Idea
CRC daemon's
/api/status
API endpoint should return correct value of preset when running CRC cluster configured withcrc
preset. At the moment it only returns correct value formicroshift
andopenshift
presets.Proposed changes
Status()
method to move ClusterStatusResult object creation logic to a separate method for easier testingTesting
Build a development version of CRC and create a cluster configured with okd preset. Then query status endpoint to see what preset is returned by API server.
crc config set preset okd
crc setup
crc start
curl -i --unix-socket ~/.crc/crc-http.sock http://crc/api/status | jq .Preset
should return"okd"
Old Behavior
Old Response of
/api/status
on OKD based cluster:New Behavior (with this PR)
New Response of
/api/status
on OKD based cluster:I have tested by cherry-picking this commit on top of #4479 , it's now displaying OKD value in
crc status
as expected.