From 51c66299e9f01b04bca2113eade13edb6d5f8f6f Mon Sep 17 00:00:00 2001 From: rock Date: Wed, 2 Sep 2026 19:52:41 -0700 Subject: [PATCH] forgejo-runner: gc every 30min instead of daily - Fix template to use .Values.gc.schedule instead of hardcoded cron - Change schedule from daily 03:00 UTC to every 30 minutes - Prevents DinD PVC fill-up (was at 93% before manual prune) --- k8s/infra/forgejo-runner/templates/gc-cronjob.yaml | 2 +- k8s/infra/forgejo-runner/values.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/k8s/infra/forgejo-runner/templates/gc-cronjob.yaml b/k8s/infra/forgejo-runner/templates/gc-cronjob.yaml index bed8ce8..abec800 100644 --- a/k8s/infra/forgejo-runner/templates/gc-cronjob.yaml +++ b/k8s/infra/forgejo-runner/templates/gc-cronjob.yaml @@ -43,7 +43,7 @@ metadata: labels: app: forgejo-runner-gc spec: - schedule: "0 2,5 * * *" # Run at 02:00 and 05:00 UTC (more frequent for heavy build workloads) + schedule: {{ .Values.gc.schedule | quote }} concurrencyPolicy: Forbid successfulJobsHistoryLimit: 3 failedJobsHistoryLimit: 3 diff --git a/k8s/infra/forgejo-runner/values.yaml b/k8s/infra/forgejo-runner/values.yaml index f4e90f0..7f18371 100644 --- a/k8s/infra/forgejo-runner/values.yaml +++ b/k8s/infra/forgejo-runner/values.yaml @@ -59,7 +59,7 @@ nodeSelector: # disable in per-runner overrides so it renders once. gc: enabled: true - schedule: "0 3 * * *" # daily 03:00 UTC + schedule: "*/30 * * * *" # every 30 minutes image: alpine/k8s:1.31.0 pruneAge: "72h" # Docker artifacts unused longer than this get pruned pruneAgeHours: 72 # Same as pruneAge but numeric for date arithmetic in shell