From bdf982c6de1a8ca5eb8ea4ccfda02a85ff620682 Mon Sep 17 00:00:00 2001 From: 0xFEEDC0DE64 Date: Sun, 18 Oct 2026 23:30:17 +0200 Subject: [PATCH] Suppress successful Authentik shell logs --- apps/authentik/verify-outposts.sh | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/apps/authentik/verify-outposts.sh b/apps/authentik/verify-outposts.sh index 1004048..d473ec1 100755 --- a/apps/authentik/verify-outposts.sh +++ b/apps/authentik/verify-outposts.sh @@ -12,9 +12,15 @@ if [ -z "$version" ]; then exit 1 fi -pins=$(kubectl --namespace authentik exec deployment/authentik-worker -- \ +shell_log=$(mktemp) +trap 'rm -f "$shell_log"' EXIT HUP INT TERM +if ! pins=$(kubectl --namespace authentik exec deployment/authentik-worker -- \ ak shell --command \ - 'from authentik.outposts.models import Outpost; [print(f"{o.name}={o.config.container_image}") for o in Outpost.objects.filter(name__in=["ldap", "radius", "rac"]).order_by("name")]') + 'from authentik.outposts.models import Outpost; [print(f"{o.name}={o.config.container_image}") for o in Outpost.objects.filter(name__in=["ldap", "radius", "rac"]).order_by("name")]' \ + 2>"$shell_log"); then + cat "$shell_log" >&2 + exit 1 +fi pin_lines=$(printf '%s\n' "$pins" | grep -E '^(ldap|rac|radius)=' || true) printf '%s\n' "$pin_lines" if [ "$(printf '%s\n' "$pin_lines" | wc -l)" -ne 3 ] || \