From 9efe5c97fe61f8bf76a05c14404c2c4bc5d1abc5 Mon Sep 17 00:00:00 2001 From: Erich Blume Date: Mon, 23 Mar 2026 21:05:16 -0700 Subject: [PATCH] Fix authentik worker OOMKill: limit concurrency to 2 Dramatiq defaults to one worker process per CPU core. On ringtail (16 cores) this spawned 16 processes, each loading the full Django app, exceeding the 1Gi memory limit and causing a crash loop (228 restarts over 7 days). Co-Authored-By: Claude Opus 4.6 (1M context) --- argocd/manifests/authentik/deployment-worker.yaml | 2 ++ docs/changelog.d/+authentik-worker-concurrency.bugfix.md | 1 + 2 files changed, 3 insertions(+) create mode 100644 docs/changelog.d/+authentik-worker-concurrency.bugfix.md diff --git a/argocd/manifests/authentik/deployment-worker.yaml b/argocd/manifests/authentik/deployment-worker.yaml index 3d4fb0c..ed8a753 100644 --- a/argocd/manifests/authentik/deployment-worker.yaml +++ b/argocd/manifests/authentik/deployment-worker.yaml @@ -53,6 +53,8 @@ spec: key: postgresql-password - name: AUTHENTIK_REDIS__HOST value: authentik-redis + - name: AUTHENTIK_WORKER_CONCURRENCY + value: "2" - name: AUTHENTIK_GRAFANA_CLIENT_SECRET valueFrom: secretKeyRef: diff --git a/docs/changelog.d/+authentik-worker-concurrency.bugfix.md b/docs/changelog.d/+authentik-worker-concurrency.bugfix.md new file mode 100644 index 0000000..f438361 --- /dev/null +++ b/docs/changelog.d/+authentik-worker-concurrency.bugfix.md @@ -0,0 +1 @@ +Fix authentik worker OOMKill by setting AUTHENTIK_WORKER_CONCURRENCY=2 (was defaulting to 16 based on CPU count).