diff --git a/sources/org.osbuild.skopeo b/sources/org.osbuild.skopeo index 72c2fef7..ee02045a 100755 --- a/sources/org.osbuild.skopeo +++ b/sources/org.osbuild.skopeo @@ -102,10 +102,8 @@ class SkopeoSource(sources.SourceService): # Verify that the digest supplied downloaded the correct container image id. # The image id is the digest of the config, but skopeo can' currently # get the config id, only the full config, so we checksum it ourselves. - res = subprocess.run(["skopeo", "inspect", "--raw", "--config", destination], - capture_output=True, - check=True) - downloaded_id = "sha256:" + hashlib.sha256(res.stdout).hexdigest() + res = subprocess.check_output(["skopeo", "inspect", "--raw", "--config", destination]) + downloaded_id = "sha256:" + hashlib.sha256(res).hexdigest() if downloaded_id != image_id: raise RuntimeError( f"Downloaded image {imagename}@{digest} has a id of {downloaded_id}, but expected {image_id}")