[libvirt] Re: Patch to python-virtinst to allow it to choose svirt labels

Cole Robinson crobinso at redhat.com
Sun Feb 22 20:34:44 UTC 2009


Daniel J Walsh wrote:

The patch didn't apply to latest upstream (there has been a lot of code
movement recently). I rediffed the patch to apply against current tip,
and made a few minor changes that don't change the overall result
(mentioned below).

> Also found at least one big bug in python-virtinst, VirtualDisk.py was
> dropping the "/" between dirname and basename of installation object,
> when you told it to create the object.
> 

This is already fixed upstream. You also had a minor bug fix in the
Installer class that is fixed as well, so I dropped both pieces.

> I think we want to have a big switch stored in libvirt somewhere saying
> whether or not we want isolated virtual machines.
> 

I think this should really be at the management tool level (i.e,
virt-manager). libvirt should be dumb in this respect, being passed a
label via the xml and doing with it what it's told.

I figure, virt-manager can have an option in Edit->Preferences,
something like "Isolate virtual machines with SELinux". Defaults to on.
If selinux isn't running, we disable the option with a tooltip
explaining why (or maybe hide it altogether). If the option is enabled,
virt-manager will assign labels to VMs at install time, and check all
active connections to avoid label collisions. More advanced behavior can
come later (assigning specific labels, some sort of collision
resolution with VMs on new connections, etc.)

Updated patch attached, I'll reply with patch specific comments later.

Thanks,
Cole
-------------- next part --------------
A non-text attachment was scrubbed...
Name: virtinst-0.400.1-svirt-02.patch
Type: text/x-diff
Size: 5741 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20090222/859c6668/attachment-0001.bin>


More information about the libvir-list mailing list