Commit Graph

219 Commits

Author SHA1 Message Date
Daniel Gollub
1730a8e5ff virtinst: add nwfilter support
This allows to make use of libvirt network filtering support with virt-install.
With the additional option "filterref" in the --network parameter one can
configure any defined nwfilter per network interface, i.e.:
virt-install ... --network network=mynet,model=virtio,filterref=clean-traffic

(crobinso: add an xmlparse test case)
2013-08-29 11:44:40 -04:00
Cole Robinson
9d11c7eae3 virtinst: Add DomainSnapshot object and some plumbing
Just for parsing domainsnapshot XML and performing some support checks
2013-08-21 18:26:27 -04:00
Martin Kletzander
3b9c397d11 Handle storage formats properly
This simple patch fixes three issues:

 1) We used only one list of storage formats.  However, we are able to
    use some formats which we cannot create.  This patch adds a list
    called 'no_create_formats' and moves such formats (currently only
    one) into it and uses new parameter 'create' which describes
    whether such formats should be removed or not.

 2) When creating new storage with the above fixed, we need to set the
    combobox's text to "" in order not to change it to "raw".  This
    was already done in reset_state(), but we need it also when
    toggle_storage_select() happens and it doesn't hurt in
    set_initial_state(), so I abstracted the implementation into
    populate_disk_format_combo().

 3) It's a bit unrelated, but when bus of a domain disk gets changed
    (in details.py), the address was not cleaned up properly ('target'
    attribute was still kept), so I fixed up the VirtualDeviceAddress
    as well.

Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=907289
2013-08-21 11:12:42 +02:00
Martin Kletzander
64b1ca15f2 Fix UUID generation according to RFC 4122
In commit 74aa8c8a, I somehow made an off-by-one error even though
that code was almost copy-paste from libvirt's commit 396c4d34.
2013-08-19 10:56:56 +02:00
Cole Robinson
8460af9a99 VirtualWatchdog: Add dump action 2013-08-18 16:06:18 -04:00
Cole Robinson
e52f6050fa qemu ARM support: wire up virtio, fix a bunch of defaults
This has some fallout on non-x86 tests which were wrong to begin with.
There's still some missing bits but this is the jist of it.
2013-08-18 12:30:58 -04:00
Cole Robinson
414f6bbd99 guest: Use virtio on plain qemu on x86
It's been available for a long long time, and unifies code paths.
2013-08-17 18:00:31 -04:00
Cole Robinson
a8858cd366 osdict: Don't run support checks, make the caller do it
Some ARM bits we are about to add would substantially complicate the
current setup, so move all the logic into guest.py where we can be
more flexible. I think this is closer to what libosinfo will give us
as well.
2013-08-17 17:53:17 -04:00
Cole Robinson
3130f64e35 VirtualDisk: Add is_disk, is_cdrom, is_floppy helpers 2013-08-17 14:21:30 -04:00
Cole Robinson
c67bd587b7 osdict: Add solaris 11 (bz 894017) 2013-08-17 10:37:59 -04:00
Cole Robinson
cfe771cf4a VirtualDisk: Add error_policy 'report' value 2013-08-17 10:35:44 -04:00
Cole Robinson
e02fa9b4fe virt-install: Add --boot dtb=DTB support
Allows passing in a device tree binary to the guest. Needed for
some non-x86 configurations.
2013-08-16 19:25:26 -04:00
Cole Robinson
cc75bc9311 guest: Remove needless functions
And simplify some test infrastructure as a result
2013-08-14 19:43:02 -04:00
Cole Robinson
7323b58862 osdict: Add Fedora 20 2013-08-12 13:32:30 -04:00
Cole Robinson
81ce0a1085 osdict: Clean up 'default' handling usage
- Unify looking up osdict values
- Have Guest.py pass in its defaults, not encoding them in osdict
- Explicitly specify every device parameter that osdict handles, rather
    than have some psuedo magic dictionary format to handle it
2013-08-12 13:31:47 -04:00
Cole Robinson
f220e6778c Guest: Drop OS listing helpers, and OS_TYPES back compat 2013-08-11 14:52:30 -04:00
Cole Robinson
e07154f997 osdict: Drop solaris back compat bits
Once upon a time solaris entries has typename="unix", but were moved to
typename="solaris". We maintained a link to the unix type for back compat,
but now the distinction doesn't matter at all, so drop it.
2013-08-11 13:52:53 -04:00
Cole Robinson
c426d5a16f Guest: Drop os_type, just use single os_variant
Internally the distinction hasn't been valuable for a long time,
so simplify the API here.
2013-08-11 12:39:36 -04:00
Cole Robinson
45d2db887d virt-*: Unify handling of --os-variant
And hide --os-type from the cli since it is long since redundant.
2013-08-11 12:39:28 -04:00
Cole Robinson
f1cb3dfa04 Guest: Remove needless _OS_TYPES storage 2013-08-11 12:39:28 -04:00
Cole Robinson
f1bf4c7188 osdict: Allow inheiriting from another OS entry 2013-08-11 12:39:28 -04:00
Cole Robinson
3ef81d5d1e osdict: Convert opencoded dicts to explicit classes
Right now this is a no-op, but will be used to simplify things
further.
2013-08-11 12:39:28 -04:00
Cole Robinson
d328b311ec support: Drop open coded dict, use classes 2013-08-11 12:39:28 -04:00
Cole Robinson
3e158b80bf guest: Move cpuset static functions to DomainNumatune 2013-08-11 12:39:28 -04:00
Cole Robinson
d36f953142 guest: Move all console handling to virt-install, the only consumer 2013-08-11 12:39:28 -04:00
Cole Robinson
090f663a6a guest: Drop removeOld parameter, just use Guest.replace 2013-08-11 12:39:28 -04:00
Cole Robinson
87789548ba guest: Drop consolecb and wait parameters from start_install 2013-08-11 12:39:28 -04:00
Cole Robinson
d403bcdcd4 Guest: Simplify init ordering 2013-08-11 12:39:28 -04:00
Cole Robinson
737d3e60f3 urlfetcher: Drop old SUSE RPM hacking
This is for an old old distro which has seen servicepack-esque updates
that invalidate all this hacking. It's basically impossible to test
anyways.
2013-08-11 12:39:28 -04:00
Cole Robinson
7c55cfeb39 virtManager: Drop util, combine it with virtinst.util and uihelpers 2013-08-11 12:39:28 -04:00
Cole Robinson
952708f509 virtinst: Rename most files to be more sensible
- Lower case everything
- Virtual... -> device...
- A few other similar bits
2013-08-09 08:54:39 -04:00
Cole Robinson
01629d3f2c virtinst: Combine ImageInstaller and ImageParser code
They aren't touched much these days, so unify the files for clarity.
2013-08-08 21:00:37 -04:00
Cole Robinson
accff84ecc virtinst: Fix import ordering to standardize on relative imports
Kind of annoying that some imports were directly from files while
some were from the __init__.py convenience bits.
2013-08-08 20:49:50 -04:00
Cole Robinson
071860f9c0 Fix some pylint 2013-08-08 20:49:50 -04:00
Cole Robinson
8f1bc4decb virtinst: Combine ImageFetcher and OSDistro
They are all involved with fetching distro URLs
2013-08-08 20:49:50 -04:00
Cole Robinson
68ddb9d885 capabilities: Drop workarounds for long gone libvirt bugs
These were both fixed 4-5 years ago
2013-08-08 19:41:39 -04:00
6e4bafc58c add ALT Linux support 2013-08-08 15:21:59 -04:00
Tomoki Sekiyama
419b34bb2e VirtualCharDevice: Enable channels with char devices other than spicevmc
Currently, virt-manager supports adding spicevmc channel, and cannot add
channels with char device backends like pty or unix, which is often used by
guest agents. On the other hand, spicevmc shows up for serial and parallel
devices, that causes an error if chosen.

This enables virt-manager to add channels with a char device backend other
than spicevmc, and hides spicevmc from non-channel devices.

Signed-off-by: Tomoki Sekiyama <tomoki.sekiyama@hds.com>
2013-08-08 14:29:15 -04:00
Cole Robinson
00e0057868 cli: Fix some comment spacing 2013-07-31 09:28:35 -04:00
Lars Seipel
72648c9185 Fix rawhide URL installs
https://bugzilla.redhat.com/show_bug.cgi?id=989162
2013-07-29 12:28:22 -04:00
Marcus Karlsson
1004ad7a23 osdict: Add FreeBSD 10
FreeBSD 10 is an upcoming release of FreeBSD. It supports virtio by
default, unlike earlier releases of FreeBSD. Add it to osdict.
2013-07-29 11:22:27 -04:00
Marcus Karlsson
eb93aec4af osdict: Add FreeBSD 9
FreeBSD 9 is the current production release of FreeBSD. Add it to
osdict, using the same properties as FreeBSD 8.
2013-07-29 11:22:27 -04:00
Cole Robinson
a23e30eb2d xmlbuilder: Fix clearing address.domain element
Our scheme for not unlinking a root node would cause issues if trying
to clear a @domain property when the root node was <domain>, even
if they are unrelated.
2013-07-29 10:45:37 -04:00
Martin Kletzander
5208c5f321 Fix progress bars in virt-clone once more
Commit 665375db was meant to fix the progress bar problems, but as
I've found out just made one race (which still persisted) a little
less probable.  The real problem was in the upper code which meant to
finish the progress bar properly, however this was not done thanks to
'finally' statement being not executed when the function returned in
the 'try' part.  This patch makes the upper caller wait for the
updating thread to finish and then properly end()s the progress bar's
output.
2013-07-26 10:08:42 +02:00
Cole Robinson
85f1e1d4b1 Fix remote URL installs
We need to make sure the pool cache is invalidated if we create
the boot-scratch pool. Also share code that builds a volinstall instance.
2013-07-25 16:21:30 -04:00
Cole Robinson
03bd6f024e xmlbuilder: Fix setting float value for is_int 2013-07-25 15:31:40 -04:00
Cole Robinson
63a3fb3066 Guest: Split up set_device_defaults for clarity 2013-07-25 15:04:47 -04:00
Cole Robinson
bf7773ce58 Guest: Drop add_device set_defaults option
Was only used to fix one bug, but has too many side effects. Just
fix it at the caller.
2013-07-25 15:04:47 -04:00
Cole Robinson
695c4b7189 VirtualDisk: Make the driver/type auto changes opt-in
It was hard to get this right, so just require that any API users
which are changing the path of an existing disk call sync_path_props()
2013-07-25 15:04:47 -04:00
Cole Robinson
bdfb86fd06 xmlbuilder: Break out much of the xml handling to a separate class
Clears things up a bit.
2013-07-25 15:04:47 -04:00