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

OVF package enhancements #3640

Merged
merged 3 commits into from
Dec 6, 2024
Merged

Conversation

akutz
Copy link
Member

@akutz akutz commented Dec 5, 2024

Description

This PR includes several enhancements to the ovf package:

  • The OVF parser now conform to the DMTF spec for OVF content. This includes:

    • support for VirtualSystemCollection
    • a single OperatingSystem section in VirtualSystem
    • removing the roll-up sections at the root of the Envelope that belong only under a VirtualSystem or VirtualSystemCollection
    • ⚠️ Breaking ⚠️ Users of the ovf package will need to update their sources to conform to the changes from this patch. It should be a fairly simple change.
  • The OVF parser now supports an enum used to define the CIM ResourceType.

    • ⚠️ Breaking ⚠️ Users of the ovf package may need to cast ResourceType to a uint16 depending on how they have used the value.
  • It is now possible to transform an ovf.Envelope into a types.VirtualMachineConfigSpec

Closes: #(issue-number)

How Has This Been Tested?

go test -v -count 1 ./ovf

Guidelines

Please read and follow the CONTRIBUTION guidelines of this project.

@akutz akutz force-pushed the feature/ovf-to-configspec branch from 52c5643 to c3b2699 Compare December 5, 2024 16:16
akutz added 2 commits December 5, 2024 10:16
This patch updates the OVF parser to conform to the DMTF spec
for OVF content. This includes:

* support for VirtualSystemCollection
* a single OperatingSystem section in VirtualSystem
* removing the roll-up sections at the root of the Envelope
  that belong only under a VirtualSystem or VirtualSystemCollection

BREAKING: Users of the `ovf` package will need to update their
          sources to conform to the changes from this patch. It
          should be a fairly simple change.

Signed-off-by: akutz <[email protected]>
This patch adds support to the OVF parser for an enum used to
define the CIM ResourceType.

BREAKING: Users of the `ovf` package may need to cast ResourceType
          to a uint16 depending on how they have used the value.

Signed-off-by: akutz <[email protected]>
@akutz akutz force-pushed the feature/ovf-to-configspec branch 3 times, most recently from 15122e3 to 8a94715 Compare December 5, 2024 17:11
ovf/configspec.go Fixed Show fixed Hide fixed
ovf/configspec.go Fixed Show fixed Hide fixed
@akutz akutz force-pushed the feature/ovf-to-configspec branch 2 times, most recently from aab302e to 9800cf9 Compare December 5, 2024 17:41
dougm
dougm previously approved these changes Dec 5, 2024
Copy link
Member

@dougm dougm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow this is great, thanks @akutz !

ovf/configspec.go Outdated Show resolved Hide resolved
@akutz akutz force-pushed the feature/ovf-to-configspec branch 2 times, most recently from f7b18ec to b02268b Compare December 5, 2024 19:20
@akutz akutz requested a review from dougm December 5, 2024 19:22
dougm
dougm previously approved these changes Dec 5, 2024
This patch provides a utility function for transforming an
OVF envelop into a ConfigSpec.

Signed-off-by: akutz <[email protected]>
@akutz akutz force-pushed the feature/ovf-to-configspec branch from b02268b to 495a820 Compare December 6, 2024 14:45
@akutz akutz requested a review from dougm December 6, 2024 14:45
@akutz akutz merged commit 8b2a311 into vmware:main Dec 6, 2024
11 checks passed
@akutz akutz deleted the feature/ovf-to-configspec branch December 6, 2024 15:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants