def is_iscsi(): """If the system is iSCSI """ from ovirt.node.config import defaults if defaults.Installation().retrieve()["iscsi_install"]: return True
def prepare(self): cfg = self.config # Data size get's a special handling because it grabs the # remaining space data_size = cfg.get("storage.data_size", "-1") data_size = data_size if int(data_size) >= 0 else "-1" self.logger.debug("Using a data_size of %s" % data_size) model = defaults.Installation() model.install_on(init=[cfg["boot.device.current"]] + cfg["installation.devices"], root_size=cfg["storage.root_size"], efi_size=cfg["storage.efi_size"], swap_size=cfg["storage.swap_size"], logging_size=cfg["storage.logging_size"], config_size=cfg["storage.config_size"], data_size=data_size) kbd = defaults.Keyboard() kbd.update(self.config["keyboard.layout"]) vercfg = defaults.ConfigVersion() vercfg.set_to_current()
def prepare(self): # Update/Write the config file cfg = self.config model = defaults.Installation() model.install_on(init=[cfg["boot.device"]] + cfg["installation.devices"], root_size=cfg["storage.root_size"], efi_size=cfg["storage.efi_size"], swap_size=cfg["storage.swap_size"], logging_size=cfg["storage.logging_size"], config_size=cfg["storage.config_size"], data_size=cfg["storage.data_size"]) kbd = defaults.Keyboard() kbd.update(self.config["keyboard.layout"])
def __init__(self): self._model = defaults.Installation() super(BootInformation, self).__init__()