-
Notifications
You must be signed in to change notification settings - Fork 3
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
[FEATURE] Redfish support #2
Comments
Just FYI https://github.com/openshift-metal3/fakefish have something for faking redfish for KubeVirt instances |
Hey @e-minguez thanks for the pointer. The way FakeFish works looks interesting. I should've found it earlier. Nevertheless, this gave me some ideas... |
So there are different levels of faking for a Redfish server...
Since our use cases involve POST actions, such as power management, we're more likely to implement a tiny but self-contained emulator. I've checked several implementations on the Internet, but I only found one project that uses the OpenAPI generator to generate the client library in Go from the DMTF-published DSP8010 Redfish OpenAPI schema. My current plan is to use a Golang-based OpenAPI generator [1][2] to generate models and server stubs from the Redfish OpenAPI schema. It turns out this isn't as easy as I imagine at the beginning. The Golang OpenAPI generators have their own limitations and they're both not as mature as the Java-based openapi-generator. Moreover, the Redfish OpenAPI schema is gigantic and uses some cryptic (or should I say erroneous) OpenAPI syntax that I'm unfamiliar with. I might go the other way around to trim down the schema a bit since we wouldn't support that many endpoints and resources. Because of that, we'll stick to a specific Redfish version. Though that seems lame, it might be the only way that I can see. If my plan B is not going well, we'll need to fallback to JSON templates, which makes me arrrr... |
My methods for verifying whether our Redfish implementation works mainly involve ad-hoc curl commands, but that might not be sufficient. I know KubeVirtBMC is far from a certified/validated Redfish device, but I'll try to make it as close as possible. Right now, I'll try to drop it into the workflow of the Tinkerbell use case and see what will happen. |
Rufio is complaining about the returned Redfish ComputerSystem resource:
|
So the "OperatingSystem"-unmarshalling issue was raised in stmcginnis/gofish#364 and has already been fixed on the main branch (not yet shipped in any releases). But Rufio v0.5.2 depends on bmclib v2.3.4, which depends on gofish v0.19.0. It's relatively complex for us to build everything ourselves just for a working demo. We can wait for those projects to bump their dependencies eventually. In the meantime, I'll try to modify the generated model and implementation of KubeVirtBMC to see if that's the only issue. I'll also look into Metal3 as a possible replacement for the demo. |
Is your feature request related to a problem? Please describe.
Currently, KubeBMC only supports limited IPMI functionalities for KubeVirt VMs. It would also be helpful to support Redfish as it is newer, feature-rich, and gradually becomes dominant in such areas.
Describe the solution you'd like
A set of Redfish APIs that supports users to communicate with to instruct KubeBMC to:
for KubeVirt VMs.
Describe alternatives you've considered
N/A
Additional context
We could implement the following resources to provide a minimum viable functionalities. Kudos to @rwleea!
The text was updated successfully, but these errors were encountered: