From 60dfce3ca2e6a67ff81edaf869e28c81db8d8b8f Mon Sep 17 00:00:00 2001 From: Pengfei Ding <9438483+dingp@users.noreply.github.com> Date: Sun, 22 Dec 2024 17:05:12 -0800 Subject: [PATCH 1/2] fix #134 use the trusted top layer id from image info --- podman_hpc/migrate2scratch.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/podman_hpc/migrate2scratch.py b/podman_hpc/migrate2scratch.py index 1347191..552999b 100755 --- a/podman_hpc/migrate2scratch.py +++ b/podman_hpc/migrate2scratch.py @@ -422,11 +422,11 @@ def migrate_image(self, image): return False img_id = img_info["id"] + top_id = img_info["layer"] # Get the layers from the manifest - rld = self._get_img_layers(self.src, img_info["layer"]) + rld = self._get_img_layers(self.src, top_id) # make sure the src squash file exist - top_id = rld[-1]["id"] logging.debug(f"Reading link: {top_id}") if self.dst.chk_image(img_id): @@ -468,11 +468,11 @@ def remove_image(self, image): logging.error(f"Image {image} not found\n") return False img_id = img_info["id"] + top_id = img_info["layer"] # Get the layers from the manifest - rld = self._get_img_layers(self.dst, img_info["layer"]) + rld = self._get_img_layers(self.dst, top_id) # make sure the src squash file exist - top_id = rld[-1]["id"] ln = self.dst.read_link_file(top_id) sqf = self.dst.get_squash_filename(ln) if os.path.exists(sqf): From 4fdbea2febae5189e1c5a8f05e485890408c7e2c Mon Sep 17 00:00:00 2001 From: Pengfei Ding <9438483+dingp@users.noreply.github.com> Date: Mon, 23 Dec 2024 08:34:51 -0800 Subject: [PATCH 2/2] advance version to v1.1.4 --- podman_hpc/podman_hpc.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/podman_hpc/podman_hpc.py b/podman_hpc/podman_hpc.py index 38b7ae3..4663a4e 100755 --- a/podman_hpc/podman_hpc.py +++ b/podman_hpc/podman_hpc.py @@ -15,7 +15,7 @@ from subprocess import Popen, PIPE -__version__ = "1.1.3" +__version__ = "1.1.4" def _round_nearest(x, a):