Example #1
0
 def set_power_type(self, power_type):
     # FIXME: modularize this better
     if power_type is None:
         power_type = ""
     choices = utils.get_power_types()
     if not choices:
         raise CX("you need to have fence-agents installed")
     if power_type not in choices:
         raise CX("power management type must be one of: %s" % ",".join(choices))
     self.power_type = power_type
Example #2
0
 def set_power_type(self, power_type):
     # FIXME: modularize this better
     if power_type is None:
         power_type = ""
     choices = utils.get_power_types()
     if not choices:
         raise CX("you need to have fence-agents installed")
     if power_type not in choices:
         raise CX("power management type must be one of: %s" % ",".join(choices))
     self.power_type = power_type
     return True
Example #3
0
 ["netboot_enabled", True, 0, "Netboot Enabled", True, "PXE (re)install this machine at next boot?", 0, "bool"],
 ["kickstart", "<<inherit>>", 0, "Kickstart", True, "Path to kickstart template", 0, "str"],
 ["comment", "", 0, "Comment", True, "Free form text description", 0, "str"],
 ["depth", 2, 0, "", False, "", 0, "int"],
 ["server", "<<inherit>>", 0, "Server Override", True, "See manpage or leave blank", 0, "str"],
 ["virt_path", "<<inherit>>", 0, "Virt Path", True, "Ex: /directory or VolGroup00", 0, "str"],
 ["virt_type", "<<inherit>>", 0, "Virt Type", True, "Virtualization technology to use", ["<<inherit>>", "xenpv", "xenfv", "qemu", "kvm", "vmware", "openvz"], "str"],
 ["virt_cpus", "<<inherit>>", 0, "Virt CPUs", True, "", 0, "int"],
 ["virt_file_size", "<<inherit>>", 0, "Virt File Size(GB)", True, "", 0, "float"],
 ["virt_disk_driver", "<<inherit>>", 0, "Virt Disk Driver Type", True, "The on-disk format for the virtualization disk", "raw", "str"],
 ["virt_ram", "<<inherit>>", 0, "Virt RAM (MB)", True, "", 0, "int"],
 ["virt_auto_boot", "<<inherit>>", 0, "Virt Auto Boot", True, "Auto boot this VM?", 0, "bool"],
 ["virt_pxe_boot", 0, 0, "Virt PXE Boot", True, "Use PXE to build this VM?", 0, "bool"],
 ["ctime", 0, 0, "", False, "", 0, "float"],
 ["mtime", 0, 0, "", False, "", 0, "float"],
 ["power_type", "SETTINGS:power_management_default_type", 0, "Power Management Type", True, "Power management script to use", utils.get_power_types(), "str"],
 ["power_address", "", 0, "Power Management Address", True, "Ex: power-device.example.org", 0, "str"],
 ["power_user", "", 0, "Power Management Username", True, "", 0, "str"],
 ["power_pass", "", 0, "Power Management Password", True, "", 0, "str"],
 ["power_id", "", 0, "Power Management ID", True, "Usually a plug number or blade name, if power type requires it", 0, "str"],
 ["hostname", "", 0, "Hostname", True, "", 0, "str"],
 ["gateway", "", 0, "Gateway", True, "", 0, "str"],
 ["name_servers", [], 0, "Name Servers", True, "space delimited", 0, "list"],
 ["name_servers_search", [], 0, "Name Servers Search Path", True, "space delimited", 0, "list"],
 ["ipv6_default_device", "", 0, "IPv6 Default Device", True, "", 0, "str"],
 ["ipv6_autoconfiguration", False, 0, "IPv6 Autoconfiguration", True, "", 0, "bool"],
 ["network_widget_a", "", 0, "Add Interface", True, "", 0, "str"],        # not a real field, a marker for the web app
 ["network_widget_b", "", 0, "Edit Interface", True, "", 0, "str"],       # not a real field, a marker for the web app
 ["*mac_address", "", 0, "MAC Address", True, "(Place \"random\" in this field for a random MAC Address.)", 0, "str"],
 ["network_widget_c", "", 0, "", True, "", 0, "str"],                     # not a real field, a marker for the web app
 ["*mtu", "", 0, "MTU", True, "", 0, "str"],
Example #4
0
     "raw",
     "str",
 ],
 ["virt_ram", "<<inherit>>", 0, "Virt RAM (MB)", True, "", 0, "int"],
 ["virt_auto_boot", "<<inherit>>", 0, "Virt Auto Boot", True, "Auto boot this VM?", 0, "bool"],
 ["virt_pxe_boot", 0, 0, "Virt PXE Boot", True, "Use PXE to build this VM?", 0, "bool"],
 ["ctime", 0, 0, "", False, "", 0, "float"],
 ["mtime", 0, 0, "", False, "", 0, "float"],
 [
     "power_type",
     "SETTINGS:power_management_default_type",
     0,
     "Power Management Type",
     True,
     "Power management script to use",
     utils.get_power_types(),
     "str",
 ],
 ["power_address", "", 0, "Power Management Address", True, "Ex: power-device.example.org", 0, "str"],
 ["power_user", "", 0, "Power Management Username", True, "", 0, "str"],
 ["power_pass", "", 0, "Power Management Password", True, "", 0, "str"],
 [
     "power_id",
     "",
     0,
     "Power Management ID",
     True,
     "Usually a plug number or blade name, if power type requires it",
     0,
     "str",
 ],
Example #5
0
 ["virt_ram", "<<inherit>>", 0, "Virt RAM (MB)", True, "", 0, "int"],
 [
     "virt_auto_boot", "<<inherit>>", 0, "Virt Auto Boot", True,
     "Auto boot this VM?", 0, "bool"
 ],
 [
     "virt_pxe_boot", 0, 0, "Virt PXE Boot", True,
     "Use PXE to build this VM?", 0, "bool"
 ],
 ["depth", 2, 0, "", False, "", 0, "int"],
 ["ctime", 0, 0, "", False, "", 0, "float"],
 ["mtime", 0, 0, "", False, "", 0, "float"],
 [
     "power_type", "SETTINGS:power_management_default_type", 0,
     "Power Management Type", True, "Power management script to use",
     utils.get_power_types(), "str"
 ],
 [
     "power_address", "", 0, "Power Management Address", True,
     "Ex: power-device.example.org", 0, "str"
 ],
 ["power_user", "", 0, "Power Management Username", True, "", 0, "str"],
 ["power_pass", "", 0, "Power Management Password", True, "", 0, "str"],
 [
     "power_id", "", 0, "Power Management ID", True,
     "Usually a plug number or blade name, if power type requires it", 0,
     "str"
 ],
 ["hostname", "", 0, "Hostname", True, "", 0, "str"],
 ["gateway", "", 0, "Gateway", True, "", 0, "str"],
 [