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

Add support for importing from VMDK, VDI, VHD, VHDX formats #1669

Merged
merged 9 commits into from Apr 25, 2021

Conversation

maya-r
Copy link
Contributor

@maya-r maya-r commented Feb 18, 2021

What this PR does / why we need it:
Sometimes images are only available in these formats as file, e.g. Microsoft only offers these formats for Windows VMs.
qemu-img supports them already, we just need to allow it & test it.
It's also a lot simpler to export a file and import it than a warm import from VMware.

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Closes #1512

Special notes for your reviewer:

Release note:

Add support for importing from VMDK, VDI, VHD, VHDX formats

Vishesh Ajay Tanksale and others added 3 commits February 18, 2021 20:40
Signed-off-by: Vishesh Ajay Tanksale <vtanksale@apple.com>
Signed-off-by: Maya Rashish <mrashish@redhat.com>
vmdk, vdi, vhd, vhdx.

Signed-off-by: Maya Rashish <mrashish@redhat.com>
@kubevirt-bot kubevirt-bot added release-note Denotes a PR that will be considered when it comes time to generate release notes. dco-signoff: yes Indicates the PR's author has DCO signed all their commits. size/L labels Feb 18, 2021
@maya-r
Copy link
Contributor Author

maya-r commented Feb 21, 2021

/test pull-containerized-data-importer-e2e-k8s-1.18-nfs

pkg/image/filefmt_test.go Show resolved Hide resolved
pkg/image/qemu.go Show resolved Hide resolved
tests/datavolume_test.go Outdated Show resolved Hide resolved
tests/utils/fileConversion.go Outdated Show resolved Hide resolved
- Avoid a table rather than introducing many items
- Mention that scratch space is used as a note, and mention its
most painful repercussions.

This is probably considered user documentation, and I expect most
users won't mind that scratch space is used, so perhaps we can
devote slightly less attention to when & why it's used.

Signed-off-by: Maya Rashish <mrashish@redhat.com>
Signed-off-by: Maya Rashish <mrashish@redhat.com>
Signed-off-by: Maya Rashish <mrashish@redhat.com>
Signed-off-by: Maya Rashish <mrashish@redhat.com>
Reduces code duplication

Signed-off-by: Maya Rashish <mrashish@redhat.com>
pkg/image/filefmt.go Outdated Show resolved Hide resolved
This also makes the VDI signature longer. It's pretty long, and
we previously only checked the "<<< " parts.
This makes us more picky about what's a VDI image, and also makes
the magic string meaningful.

Signed-off-by: Maya Rashish <mrashish@redhat.com>
@brybacki
Copy link
Contributor

/lgtm

@kubevirt-bot kubevirt-bot added the lgtm Indicates that a PR is ready to be merged. label Mar 22, 2021
@maya-r
Copy link
Contributor Author

maya-r commented Apr 8, 2021

ping @mhenriks @awels @aglitke

@awels
Copy link
Member

awels commented Apr 21, 2021

/lgtm
/approve

@kubevirt-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: awels

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kubevirt-bot kubevirt-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 21, 2021
@awels
Copy link
Member

awels commented Apr 22, 2021

/retest

@awels
Copy link
Member

awels commented Apr 22, 2021

/retest

@awels
Copy link
Member

awels commented Apr 22, 2021

/test pull-containerized-data-importer-e2e-k8s-1.18-nfs

@awels
Copy link
Member

awels commented Apr 23, 2021

/retest

@maya-r
Copy link
Contributor Author

maya-r commented Apr 25, 2021

/test pull-containerized-data-importer-e2e-k8s-1.18-nfs

1 similar comment
@maya-r
Copy link
Contributor Author

maya-r commented Apr 25, 2021

/test pull-containerized-data-importer-e2e-k8s-1.18-nfs

@kubevirt-bot kubevirt-bot merged commit bd35596 into kubevirt:main Apr 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. dco-signoff: yes Indicates the PR's author has DCO signed all their commits. lgtm Indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/L
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants