From f9f13898263aff70af604314904c4bddd57fd05f Mon Sep 17 00:00:00 2001 From: Santo Cariotti Date: Wed, 8 Jan 2025 21:06:20 +0100 Subject: Add affinity rule --- yaml/deployments/cas.yaml | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'yaml') diff --git a/yaml/deployments/cas.yaml b/yaml/deployments/cas.yaml index 86dc11a..fe7c082 100644 --- a/yaml/deployments/cas.yaml +++ b/yaml/deployments/cas.yaml @@ -14,6 +14,13 @@ spec: labels: app: cas-app spec: + affinity: + podAntiAffinity: + requiredDuringSchedulingIgnoredDuringExecution: + - labelSelector: + matchLabels: + app: cas-app + topologyKey: "kubernetes.io/hostname" containers: - name: cas image: ghcr.io/cas-4/backend:latest -- cgit v1.2.3-18-g5258