ryran / upvm

Leverage virt-builder & virt-install to spin up new VMs with ease
Apache License 2.0
40 stars 9 forks source link

--info doesn't pick the right architecture when there are multiple templates of the same name & different arch #28

Closed ryran closed 8 years ago

ryran commented 8 years ago

For example, if I choose the debian-7 template, upvm and virt-builder default to my own arch, i.e., x86_64:

$ upvm debian-7
Enter VMNAME [debian-7] : 
  INFO: HOSTNAME not specified; using 'debian-7.example.com'
  INFO: Unable to determine native format of chosen template
  INFO: Using qcow2 for output format (change with --format=raw)
  INFO: Auto-detected os-variant ('debian7') was validated by osinfo-query command
  INFO: Initializing libvirt connection to qemu:///session
  INFO: Starting virt-builder
[   1.1] Downloading: http://libguestfs.org/download/builder/debian-7.xz
                                                                           1.1%^C
Received KeyboardInterrupt. Exiting.

If I try it with --info it chooses sparc64:

$ upvm debian-7 --info | head -11
template         : debian-7
osinfo           : debian7
compressed-size  : 96292208
full-name        : Debian 7 (Wheezy) (sparc64)
hidden           : False
arch             : sparc64
size             : 4294967296
notes:
Debian 7 (Wheezy).

This is a Debian 7 (Wheezy) sparc64 image.  This was not built using