tinkerbell / actions

Suite of Tinkerbell Actions for use in Tinkerbell Workflows
Apache License 2.0
28 stars 43 forks source link

Fix the metadata structure in the rootio action #88

Closed moadqassem closed 2 years ago

moadqassem commented 2 years ago

Description

The current structure of the Metadata type in the rootio action, doesn't. really match what we have in tink! this could lead to issues while decoding the payload, that's coming from Hegel. For more information, please take a look at this issue: https://github.com/tinkerbell/hub/issues/70

Why is this needed

This change is needed, to make sure that disks are being managed properly by rootio and to reflect what we have in the hardware template that comes from Hegel.

Fixes: #70

How Has This Been Tested?

I created a custom image with my changes and ran it as a workflow and it works as expected. The metadata struct was decoded correctly, the machine disks were found and managed as the hardware data states. In addition, I fixed the unit test case and made sure there is an error check if the unmarshalling didn't work match.

How are existing users impacted? What migration steps/scripts do we need?

Probably they are not effected as this issue disabled rootio to deliver a viable functionality.

Checklist:

I have:

moadqassem commented 2 years ago

@jacobweinstock a friendly reminder, PTAL :-)

jacobweinstock commented 2 years ago

Hey @nshalman, mind checking this one out?