-
Notifications
You must be signed in to change notification settings - Fork 9
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
K8s metadata #38
K8s metadata #38
Conversation
Signed-off-by: Raul Sevilla <[email protected]>
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #38 +/- ##
=======================================
Coverage 83.33% 83.33%
=======================================
Files 6 6
Lines 312 312
=======================================
Hits 260 260
Misses 38 38
Partials 14 14 ☔ View full report in Codecov by Sentry. |
…en marshalling JSON Signed-off-by: Raul Sevilla <[email protected]>
d9a5afb
to
7840ef7
Compare
metadata.ClusterType = v.Value | ||
} | ||
} | ||
metadata.SDNType, err = meta.getSDNInfo() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need SDNType
as well to be populated only when there are infra nodes present?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
infra does not refer to infra nodes but to the "infrastructure" object, which is only present in OpenShift clusters, same as config.openshift.io/v1/networks
. for that reason when the infra object is not present, we don't try to get the sdnType
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I made this mistake too @vishnuchalla
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm!
Type of change
Description
Some updates required to make this library compatible with vanilla k8s
infrastructure
or theclusterversion
resources are not found, assume that this is not an OCP cluster and return empty fields rather than crashingRelated Tickets & Documents
Checklist before requesting a review
Testing