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

Allow IMG extension for QCOW2 format #4013

Merged
merged 1 commit into from
Jun 8, 2020

Conversation

nvazquez
Copy link
Contributor

@nvazquez nvazquez commented Apr 4, 2020

Description

Attempts to register QCOW2 template with .img extension fails fast:
image

This fix allows registering a QCOW2 template with .img extension

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)

Screenshots (if appropriate):

How Has This Been Tested?

Register templates: https://cloud-images.ubuntu.com/minimal/releases/bionic/release/ubuntu-18.04-minimal-cloudimg-amd64.img, http://dl.openvm.eu/cloudstack/macchinina/x86_64/macchinina.img with format = QCOW2

@svenvogel
Copy link
Contributor

@nvazquez maybe i dont understand it correctly. a small question. for me a file with "img" extensions is normally in raw format and needs to be converted in qcow2. why we import a img as qcow2?

qemu-img convert -f raw -O qcow2 image.img image.qcow2

@rohityadavcloud
Copy link
Member

@svenvogel many distros host/build cloud-init enabled qcow2 images and ship as .img

@rohityadavcloud rohityadavcloud marked this pull request as ready for review May 27, 2020 03:54
@rohityadavcloud
Copy link
Member

@blueorangutan package

@blueorangutan
Copy link

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan
Copy link

Packaging result: ✖centos7 ✔debian. JID-1284

@rohityadavcloud
Copy link
Member

@blueorangutan package

@blueorangutan
Copy link

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan
Copy link

Packaging result: ✔centos7 ✔debian. JID-1289

@rohityadavcloud
Copy link
Member

@blueorangutan test

@blueorangutan
Copy link

@rhtyd a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

Copy link
Contributor

@DaanHoogland DaanHoogland left a comment

Choose a reason for hiding this comment

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

code looks ok at first sight, be it a bit of a hack. But img is now used in two formats. Extensive testing is needed (or we'll just wait and see?) we can run into trouble as raw images can be registered as qcow2 now, while actually more validation is required through deep inspection of the image itself?

@rohityadavcloud
Copy link
Member

img and raw are interchangeable they're using for registering raw disks/templates.

@blueorangutan
Copy link

Trillian test result (tid-1623)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 45266 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr4013-t1623-kvm-centos7.zip
Smoke tests completed. 83 look OK, 0 have error(s)
Only failed tests results shown below:

Test Result Time (s) Test File

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants