Merge pull request #141 from firstlookmedia/137-docker-exception

Ignore exceptions when there's an error deleting an old container image
This commit is contained in:
Micah Lee 2021-12-13 11:37:44 -08:00 committed by GitHub
commit 2206df0422
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -482,11 +482,14 @@ class GlobalCommon(object):
elif found_image_id == "":
pass
else:
print(f"Deleting old dangerzone container image")
print("Deleting old dangerzone container image")
try:
subprocess.check_output(
[self.get_container_runtime(), "rmi", "--force", found_image_id],
startupinfo=self.get_subprocess_startupinfo(),
)
except:
print("Couldn't delete old container image, so leaving it there")
return installed