diff --git a/CHANGELOG.md b/CHANGELOG.md index 27713b5..f2c2910 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,13 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [0.17.0] - 2025-06-16 + +### Changed + +- Removed useless warning about /dev/loop0 +- Fix windows EFI booting, and a typo + ## [0.16.0] - 2025-06-12 ### Changed diff --git a/ogclient/lib/python3/BootLib.py b/ogclient/lib/python3/BootLib.py index ac106b7..6f9e7b5 100644 --- a/ogclient/lib/python3/BootLib.py +++ b/ogclient/lib/python3/BootLib.py @@ -128,7 +128,7 @@ def ogBoot (disk, par, nvramperm=False, params=''): esp_dev = DiskLib.ogDiskToDev (efidisk, efipart) esp_mntdir = esp_dev.replace ('dev', 'mnt') - os.makedirs (f'{esp_mntdir}/boot/grub', exists_ok=True) + os.makedirs (f'{esp_mntdir}/boot/grub', exist_ok=True) shutil.copy2 (f'{esp_mntdir}/EFI/{bootlabel}/Boot/grub.cfg', f'{esp_mntdir}/boot/grub/grub.cfg') # Crear orden de arranque (con unos valores por defecto). @@ -161,6 +161,11 @@ def ogBoot (disk, par, nvramperm=False, params=''): SystemLib.ogRaiseError ([], ogGlobals.OG_ERR_NOTOS, f'{disk} {par} ({type}, EFI)') return None + esp_dev = DiskLib.ogDiskToDev (efidisk, efipart) + esp_mntdir = esp_dev.replace ('dev', 'mnt') + os.makedirs (f'{esp_mntdir}/boot/grub', exist_ok=True) + shutil.copy2 (f'{esp_mntdir}/EFI/{bootlabel}/Boot/grub.cfg', f'{esp_mntdir}/boot/grub/grub.cfg') + # Crear orden de arranque (con unos valores por defecto). l = re.sub ('^.*EFI(.*)$', r'\1', loader) UEFILib.ogNvramAddEntry (bootlabel, l, nvramperm) diff --git a/ogclient/lib/python3/DiskLib.py b/ogclient/lib/python3/DiskLib.py index 7ace30a..0b1f113 100644 --- a/ogclient/lib/python3/DiskLib.py +++ b/ogclient/lib/python3/DiskLib.py @@ -392,7 +392,8 @@ def ogDevToDisk(arg_dev): DEV = arg_dev if not os.path.exists(DEV): - SystemLib.ogRaiseError([], ogGlobals.OG_ERR_NOTFOUND, arg_dev) + if '/dev/loop' != DEV[0:9]: + SystemLib.ogRaiseError([], ogGlobals.OG_ERR_NOTFOUND, arg_dev) return # Error si no es fichero de bloques o directorio (para LVM).