diff options
author | John Estabrook <jestabro@vyos.io> | 2023-10-21 13:33:37 -0500 |
---|---|---|
committer | John Estabrook <jestabro@vyos.io> | 2023-12-16 20:37:10 -0600 |
commit | bb1c98ae64667fdc4fba7a316671d16964fb024f (patch) | |
tree | 43ce153d3d211d973034e806b331ac7309517d87 /src/op_mode/image_info.py | |
parent | 06832e3cc962eb4f94afe5319e7416d68756dba9 (diff) | |
download | vyos-1x-bb1c98ae64667fdc4fba7a316671d16964fb024f.tar.gz vyos-1x-bb1c98ae64667fdc4fba7a316671d16964fb024f.zip |
image: T4516: support for interoperability of legacy/new image tools
This commit allows management of system images with either new or legacy
tools: 'add/delete/rename system image' and 'set default' are translated
appropriately on booting between images with the old and new tools.
Consequently, the warning of the initial commit of T4516 is dropped.
(cherry picked from commit 96b65e90fbfa1fe63d97929ac86fc910abb0caa9)
Diffstat (limited to 'src/op_mode/image_info.py')
-rwxr-xr-x | src/op_mode/image_info.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/op_mode/image_info.py b/src/op_mode/image_info.py index 14dca7476..791001e00 100755 --- a/src/op_mode/image_info.py +++ b/src/op_mode/image_info.py @@ -1,6 +1,6 @@ #!/usr/bin/env python3 # -# Copyright 2022 VyOS maintainers and contributors <maintainers@vyos.io> +# Copyright 2023 VyOS maintainers and contributors <maintainers@vyos.io> # # This file is part of VyOS. # @@ -91,10 +91,7 @@ def show_images_summary(raw: bool) -> Union[image.BootDetails, str]: def show_images_details(raw: bool) -> Union[list[image.ImageDetails], str]: - images: list[str] = grub.version_list() - images_details: list[image.ImageDetails] = list() - for image_name in images: - images_details.append(image.get_details(image_name)) + images_details = image.get_images_details() if raw: return images_details |