Merge "Don't change the default attach-method"
This commit is contained in:
commit
8d8798efff
@ -24,7 +24,6 @@ class GuestFS(object):
|
||||
self.mounts = []
|
||||
self.files = {}
|
||||
self.auginit = False
|
||||
self.attach_method = 'libvirt'
|
||||
self.root_mounted = False
|
||||
|
||||
def launch(self):
|
||||
@ -41,12 +40,6 @@ class GuestFS(object):
|
||||
def add_drive_opts(self, file, *args, **kwargs):
|
||||
self.drives.append((file, kwargs['format']))
|
||||
|
||||
def get_attach_method(self):
|
||||
return self.attach_method
|
||||
|
||||
def set_attach_method(self, attach_method):
|
||||
self.attach_method = attach_method
|
||||
|
||||
def inspect_os(self):
|
||||
return ["/dev/guestvgf/lv_root"]
|
||||
|
||||
|
@ -21,7 +21,6 @@ from nova import exception
|
||||
from nova.openstack.common.gettextutils import _
|
||||
from nova.openstack.common import log as logging
|
||||
from nova.virt.disk.vfs import api as vfs
|
||||
from nova.virt.libvirt import driver as libvirt_driver
|
||||
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
@ -113,9 +112,6 @@ class VFSGuestFS(vfs.VFS):
|
||||
|
||||
try:
|
||||
self.handle.add_drive_opts(self.imgfile, format=self.imgfmt)
|
||||
if self.handle.get_attach_method() == 'libvirt':
|
||||
libvirt_url = 'libvirt:' + libvirt_driver.LibvirtDriver.uri()
|
||||
self.handle.set_attach_method(libvirt_url)
|
||||
self.handle.launch()
|
||||
|
||||
self.setup_os()
|
||||
|
Loading…
Reference in New Issue
Block a user