mirror of
https://github.com/freedomofpress/dangerzone.git
synced 2025-04-28 18:02:38 +02:00
Handle multiple image IDs in the image-ids.txt
file.
Docker Desktop 4.30.0 uses the containerd image store by default, which generates different IDs for the images, and as a result breaks the logic we are using when verifying the images IDs are present. Now, multiple IDs can be stored in the `image-id.txt` file. Fixes #933
This commit is contained in:
parent
bd2dc0ea3c
commit
4423fc6232
1 changed files with 2 additions and 2 deletions
|
@ -194,7 +194,7 @@ class Container(IsolationProvider):
|
|||
"""
|
||||
# Get the image id
|
||||
with open(get_resource_path("image-id.txt")) as f:
|
||||
expected_image_id = f.read().strip()
|
||||
expected_image_ids = f.read().strip().split()
|
||||
|
||||
# See if this image is already installed
|
||||
installed = False
|
||||
|
@ -212,7 +212,7 @@ class Container(IsolationProvider):
|
|||
)
|
||||
found_image_id = found_image_id.strip()
|
||||
|
||||
if found_image_id == expected_image_id:
|
||||
if found_image_id in expected_image_ids:
|
||||
installed = True
|
||||
elif found_image_id == "":
|
||||
pass
|
||||
|
|
Loading…
Reference in a new issue