diff options
author | Jose M. Guisado <jguisado@soleta.eu> | 2023-08-16 14:34:14 +0200 |
---|---|---|
committer | Jose M. Guisado <jguisado@soleta.eu> | 2023-09-13 15:18:11 +0200 |
commit | 457a912749f89267a7440c56e133f57522bfc164 (patch) | |
tree | 327c3eda60ad27d7522a98e1649497f64de3ecdb /src | |
parent | a72ad3e637f1d4800bd80bf75d8a9a5847ae326a (diff) |
live: drop IniciarSesion script when uefi booting
Replace IniciarSesion script in favor of native Python code when booting
a UEFI system. This applies when running the "session" command.
WIP: Only UEFI boots Windows systems. Raise NotImplementedError
exception trying to boot a Linux system using UEFI.
Diffstat (limited to 'src')
-rw-r--r-- | src/live/ogOperations.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/live/ogOperations.py b/src/live/ogOperations.py index 0998b18..5e6049d 100644 --- a/src/live/ogOperations.py +++ b/src/live/ogOperations.py @@ -31,6 +31,8 @@ from src.utils.probe import os_probe, cache_probe from src.utils.disk import * from src.utils.cache import generate_cache_txt, umount_cache, init_cache from src.utils.tiptorrent import * +from src.utils.uefi import * +from src.utils.boot import * from src.utils.sw_inventory import get_package_set from src.utils.hw_inventory import get_hardware_inventory, legacy_list_hardware_inventory @@ -253,6 +255,14 @@ class OgLiveOperations: def session(self, request, ogRest): disk = request.getDisk() partition = request.getPartition() + + if is_uefi_supported(): + logging.info('UEFI support detected') + logging.info('Booting disk={disk} partition={partition}') + boot_os_at(int(disk), int(partition)) + self.reboot() + return + cmd = f'{ogClient.OG_PATH}interfaceAdm/IniciarSesion {disk} {partition}' try: |