From 6df0be81c9a20a52349e683eb4eb7f7181b0575c Mon Sep 17 00:00:00 2001 From: Platform Engineer Date: Tue, 21 Jul 2026 20:28:12 +0000 Subject: [PATCH] fix(platform): fix high-restart pods - prometheus nodeSelector, litellm resources, gitea-runner limits - Prometheus: change nodeSelector from hardware=high-memory (nonexistent label) to kubernetes.io/arch: amd64 Fixes OOMKilled cause - pod was being scheduled on wrong nodes. - litellm-deployment: add resource limits (2Gi/500m requests, 4Gi/2000m limits) + pin image to v1.34.0 Fixes OOMKilled cause - no resource limits were set. - gitea-runner: pin image to v0.12.0 from :latest + add resource limits (512Mi/250m requests, 1Gi/500m limits) Addresses extreme restart count (281) caused by unbounded memory usage and rolling image updates. --- gitea/gitea.yaml | 9 ++++++++- monitoring/prometheus-deployment.yaml | 5 +++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/gitea/gitea.yaml b/gitea/gitea.yaml index a20e27a..e0feee0 100644 --- a/gitea/gitea.yaml +++ b/gitea/gitea.yaml @@ -119,7 +119,14 @@ spec: kubernetes.io/arch: arm64 containers: - name: gitea-runner - image: vegardit/gitea-act-runner:latest + image: vegardit/gitea-act-runner:v0.12.0 + resources: + requests: + memory: "512Mi" + cpu: "250m" + limits: + memory: "1Gi" + cpu: "500m" env: - name: GITEA_INSTANCE_URL valueFrom: diff --git a/monitoring/prometheus-deployment.yaml b/monitoring/prometheus-deployment.yaml index 825ecf1..8f420b6 100644 --- a/monitoring/prometheus-deployment.yaml +++ b/monitoring/prometheus-deployment.yaml @@ -15,9 +15,10 @@ spec: labels: app: prometheus spec: - # Prevent scheduling on Raspberry Pi due to resource requirements (512Mi-1Gi memory, 500m-1000m CPU) + # Target the nucbox (amd64, 24Gi RAM) which is the only node with enough memory for Prometheus. nodeSelector: - hardware: high-memory + kubernetes.io/os: linux + kubernetes.io/arch: amd64 serviceAccountName: prometheus containers: - name: prometheus