Skip to content

prod: authentik rollout wedged — chart pins 2024.12.3 but DB migrated to 2026.5.5 (selfHeal downgrade loop; fuzefront app Degraded) #555

Description

@izzywdev

@claude

Summary

In prod (Contabo k3s, namespace fuzefront, Argo CD app fuzefront), the authentik-server rollout is permanently wedged and it is the sole remaining reason the fuzefront Argo Application is Degraded (the app is otherwise Synced, all other workloads Healthy). SSO is not down — the old 2026.5.5 pod still serves — but the rollout can never converge and Argo selfHeal keeps fighting it.

Root cause (verified against the live cluster + this repo)

The chart pins an older authentik image than the one that actually migrated the prod DB:

  • deploy/helm/fuzefront/values.yaml pins authentik ... tag: "2024.12.3".
  • 2026.5.5 appears nowhere in this repo (0 matches).

Sequence:

  1. ~31h ago authentik was upgraded to 2026.5.5 directly on the cluster (out-of-band; never committed). That ran authentik's irreversible forward DB migrations and is the healthy 1/1 pod serving SSO now.
  2. Argo selfHeal saw live (2026.5.5) != git (2024.12.3) and reverted the image to 2024.12.3 (new RS authentik-server-6df5b695ff, ~28h old). 2024.12.3 cannot run against the 2026.5.5-migrated DB, so it crashloops. The old 2026.5.5 RS (authentik-server-f6f79cf5f) lingers 1/1 only because the new pod never became Ready (maxUnavailable=0).

Live evidence:

Deployment authentik-server desired image: ghcr.io/goauthentik/server:2024.12.3
RS authentik-server-6df5b695ff  image 2024.12.3  desired=1 ready=0  (crashloop, ~28h)
RS authentik-server-f6f79cf5f   image 2026.5.5   desired=1 ready=1  (serving, ~31h)
authentik-worker                image 2024.12.3  (tasks erroring against DB)

Crash logs from the 2024.12.3 pods (schema is ahead of the code):

column authentik_core_authenticatedsession.session_key does not exist   (HINT: session_id)
column authentik_core_authenticatedsession.expiring does not exist
relation "authentik_events_systemtask" does not exist

The authentik-config-apply hook then fails on every sync (can't reach a healthy authentik), which is what pins the Argo app at Degraded.

Fix (GitOps — align the chart to the already-migrated DB)

Authentik DB migrations are one-way — you cannot downgrade to 2024.12.3. Roll the chart forward to match the DB:

# deploy/helm/fuzefront/values.yaml  (authentik server image)
-    tag: "2024.12.3"
+    tag: "2026.5.5"

Commit to master → Argo syncs → the 2026.5.5 RS becomes Ready → old RS scales to 0 → authentik-config-apply hook succeeds → fuzefront app goes Healthy. Must land via Git→Argo; do NOT kubectl set image (that out-of-band change is exactly what caused this — selfHeal reverts it).

Also align the non-prod references for consistency (they do not affect prod): docker-compose.yml, docker-compose.e2e.yml, and the deploy/e2e/provision-authentik-oidc.sh comments all still say 2024.12.3.

Acceptance criteria

  • deploy/helm/fuzefront/values.yaml authentik server tag: "2026.5.5".
  • New authentik-server RS on 2026.5.5 reaches 1/1; the 2024.12.3 RS scales to 0.
  • authentik-worker on 2026.5.5, no schema errors in its log.
  • authentik-config-apply hook completes; Argo fuzefront Application = Synced / Healthy.

STATE

DONE:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions