[node-patches] Change in ovirt-node[node-3.0]: installer: Data disk initially same as boot disk

fabiand at fedoraproject.org fabiand at fedoraproject.org
Wed Feb 19 14:15:46 UTC 2014


Fabian Deutsch has uploaded a new change for review.

Change subject: installer: Data disk initially same as boot disk
......................................................................

installer: Data disk initially same as boot disk

Previously the first enumerated disk was the default on the installation
device page.
To behave like the old installer, now the installation disk is initially
set to be the same disk as the boot disk.

Change-Id: I961b736385876cf8c17f30eadea053ae58435f73
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1062249
Signed-off-by: Fabian Deutsch <fabiand at redhat.com>
---
M src/ovirt/node/installer/core/installation_device_page.py
M src/ovirt/node/installer/core/storage_vol_page.py
2 files changed, 6 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-node refs/changes/76/24776/1

diff --git a/src/ovirt/node/installer/core/installation_device_page.py b/src/ovirt/node/installer/core/installation_device_page.py
index f035890..be6d47b 100644
--- a/src/ovirt/node/installer/core/installation_device_page.py
+++ b/src/ovirt/node/installer/core/installation_device_page.py
@@ -45,7 +45,12 @@
         devices = self.storage_discovery.all_devices_for_ui_table()
         self.logger.debug("Available devices: %s" % devices)
         if devices:
+            selected_boot_dev = \
+                self.application.plugins()["Boot Device"]\
+                .model()["boot.device.current"]
             first_dev = devices[0][0]
+            if selected_boot_dev in devices:
+                first_dev = selected_boot_device
             self._model["installation.device.details"] = first_dev
             self._model["installation.device.current"] = first_dev
         return self._model
diff --git a/src/ovirt/node/installer/core/storage_vol_page.py b/src/ovirt/node/installer/core/storage_vol_page.py
index 008e0e3..a0e4a3a 100644
--- a/src/ovirt/node/installer/core/storage_vol_page.py
+++ b/src/ovirt/node/installer/core/storage_vol_page.py
@@ -144,6 +144,7 @@
 
     def __get_default_sizes(self):
         if self.application.args.dry:
+            self._drive_size = 42 * 1024
             return {"storage.efi_size": "256",
                     "storage.root_size": "50",
                     "storage.swap_size": "0",


-- 
To view, visit http://gerrit.ovirt.org/24776
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I961b736385876cf8c17f30eadea053ae58435f73
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-node
Gerrit-Branch: node-3.0
Gerrit-Owner: Fabian Deutsch <fabiand at fedoraproject.org>



More information about the node-patches mailing list