summaryrefslogtreecommitdiff
path: root/virt-install
diff options
context:
space:
mode:
Diffstat (limited to 'virt-install')
-rwxr-xr-xvirt-install11
1 files changed, 7 insertions, 4 deletions
diff --git a/virt-install b/virt-install
index 03ed324e..57875b0e 100755
--- a/virt-install
+++ b/virt-install
@@ -507,6 +507,7 @@ def set_cli_defaults(options, guest):
def build_guest_instance(conn, options):
guest = virtinst.Guest(conn)
+ guest.skip_default_osinfo = True
if options.name:
guest.name = options.name
@@ -523,10 +524,6 @@ def build_guest_instance(conn, options):
if options.machine:
guest.os.machine = options.machine
- # If explicit os-variant requested, set it early since it will
- # provide more defaults in the future
- options.os_variant.set_os_name(guest)
-
cli.parse_option_strings(options, guest, None)
# Call set_capabilities_defaults explicitly here rather than depend
@@ -534,6 +531,12 @@ def build_guest_instance(conn, options):
# However we want to do it after parse_option_strings to ensure
# we are operating on any arch/os/type values passed in with --boot
guest.set_capabilities_defaults()
+
+ # If explicit os-variant requested, set it early since it will
+ # provide more defaults in the future
+ guest.set_default_os_name()
+ options.os_variant.set_os_name(guest)
+
installer = build_installer(options, guest)
set_cli_defaults(options, guest)