From 56c7686e37b7947bed36d0377a665c21248f5cd8 Mon Sep 17 00:00:00 2001 From: Aaron Fiore Date: Wed, 4 Feb 2026 16:59:44 -0800 Subject: [PATCH] repo: gitea: workflows: dfi: impl: force remove `dfi` images As a result of the `backup` action, images were not actually removed: "image is referenced in multiple repositories" --- .gitea/workflows/dfi.bash | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/dfi.bash b/.gitea/workflows/dfi.bash index 1ec90b6..0636007 100755 --- a/.gitea/workflows/dfi.bash +++ b/.gitea/workflows/dfi.bash @@ -41,9 +41,9 @@ function host::clean() || echo "No docker-finance containers found" # Remove all images not in use - local -r _images=("$(docker images -aq)") + local -r _images=("$(docker images -a --format=table | grep docker-finance | gawk '{print $3}' | sort -u)") while read _line; do - docker image rm "$_line" || continue + docker image rm -f "$_line" || continue done < <(echo "${_images[@]}") # Remove all leftovers