Files
platform-core/services/priority-classes/priority-classes.yaml
T
DongHyeonka c2a3f75bc3 feat(priority): add platform-critical and platform-low PriorityClasses
Every platform pod runs at priority 0. During the 2026-11-09 disk
eviction the tech-log production pods were ranked with Grafana and
kube-state-metrics. The kubelet ranks evictions by usage over requests
and then by priority, so without classes the database and the
production app have no head start.

Add two classes and attach nothing yet: platform-critical (1000000,
may preempt) for platform-postgres, Gitea, Keycloak and tech-log, and
platform-low (-1000, never preempts) for Grafana, pgAdmin, Loki and
Tempo. Neither is the global default, so no pod changes silently.

Risk: creating the classes changes no pod. Attaching them restarts the
pods, so that is left for the k3s restart window.

Verification: render-tenants-and-policies.sh (added later in this
series) checks the values, the preemption policy and globalDefault.
2026-11-12 00:28:57 +09:00

26 lines
743 B
YAML

apiVersion: scheduling.k8s.io/v1
kind: PriorityClass
metadata:
name: platform-critical
labels:
app.kubernetes.io/part-of: platform
value: 1000000
globalDefault: false
preemptionPolicy: PreemptLowerPriority
description: >-
Stateful platform services and production workloads that other services depend on
(platform-postgres, Gitea, Keycloak, tech-log). Evicted after everything else.
---
apiVersion: scheduling.k8s.io/v1
kind: PriorityClass
metadata:
name: platform-low
labels:
app.kubernetes.io/part-of: platform
value: -1000
globalDefault: false
preemptionPolicy: Never
description: >-
Tools whose loss does not stop a user-facing service (Grafana, pgAdmin, Loki, Tempo).
Evicted first and never preempts another pod.