From 8d2e576fc26a4c792d73f2f09a22faad66d6c6b9 Mon Sep 17 00:00:00 2001 From: Eric Trenkel Date: Sat, 17 Jan 2026 08:52:08 +0100 Subject: [PATCH] Add workaround for stale gpg-agent socket in entrypoint scripts --- build/entrypoint.sh | 6 ++++++ deb/entrypoint.sh | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/build/entrypoint.sh b/build/entrypoint.sh index 1931087..df71743 100644 --- a/build/entrypoint.sh +++ b/build/entrypoint.sh @@ -2,6 +2,12 @@ set -ex +# Workaround for stale gpg-agent socket causing auth failures on restart +# Cleans up leftover sockets in the GPG home directory +if [ -d /root/.gnupg ]; then + rm -f /root/.gnupg/S.gpg-agent* +fi + # Initialize if [[ $1 == init ]]; then diff --git a/deb/entrypoint.sh b/deb/entrypoint.sh index 13637e5..3f81e42 100644 --- a/deb/entrypoint.sh +++ b/deb/entrypoint.sh @@ -2,6 +2,12 @@ set -ex +# Workaround for stale gpg-agent socket causing auth failures on restart +# Cleans up leftover sockets in the GPG home directory +if [ -d /root/.gnupg ]; then + rm -f /root/.gnupg/S.gpg-agent* +fi + # Initialize if [[ $1 == init ]]; then