summaryrefslogtreecommitdiffstats
path: root/cobbler
diff options
context:
space:
mode:
Diffstat (limited to 'cobbler')
-rw-r--r--cobbler/item_profile.py2
-rw-r--r--cobbler/item_system.py2
-rw-r--r--cobbler/modules/cli_system.py6
3 files changed, 7 insertions, 3 deletions
diff --git a/cobbler/item_profile.py b/cobbler/item_profile.py
index ddb36ba..594c5fb 100644
--- a/cobbler/item_profile.py
+++ b/cobbler/item_profile.py
@@ -270,7 +270,7 @@ class Profile(item.Item):
self.virt_type == "<<inherit>>"
return True
- if vtype.lower() not in [ "qemu", "xenpv", "auto" ]:
+ if vtype.lower() not in [ "qemu", "xenpv", "xenfv", "auto" ]:
raise CX(_("invalid virt type"))
self.virt_type = vtype
return True
diff --git a/cobbler/item_system.py b/cobbler/item_system.py
index 4bfd763..9903042 100644
--- a/cobbler/item_system.py
+++ b/cobbler/item_system.py
@@ -275,7 +275,7 @@ class System(item.Item):
"""
Virtualization preference, can be overridden by koan.
"""
- if vtype.lower() not in [ "qemu", "xenpv", "auto" ]:
+ if vtype.lower() not in [ "qemu", "xenpv", "xenfv", "auto" ]:
raise CX(_("invalid virt type"))
self.virt_type = vtype
return True
diff --git a/cobbler/modules/cli_system.py b/cobbler/modules/cli_system.py
index dc7e6bc..4056359 100644
--- a/cobbler/modules/cli_system.py
+++ b/cobbler/modules/cli_system.py
@@ -78,7 +78,11 @@ class SystemFunction(commands.CobblerFunction):
if self.options.virt_path: obj.set_virt_path(self.options.virt_path)
if self.options.virt_type: obj.set_virt_type(self.options.virt_type)
- my_interface = "intf%s" % self.options.interface
+ if self.options.interface:
+ my_interface = "intf%s" % self.options.interface
+ else:
+ my_interface = "intf0"
+
if self.options.hostname: obj.set_hostname(self.options.hostname, my_interface)
if self.options.mac: obj.set_mac_address(self.options.mac, my_interface)
if self.options.ip: obj.set_ip_address(self.options.ip, my_interface)