Browse Source

Try to spread redis pod apart

Victor Lavaud 7 months ago
parent
commit
8b1197a6cc
1 changed files with 14 additions and 0 deletions
  1. 14 0
      redis/values.yaml

+ 14 - 0
redis/values.yaml

@@ -10,10 +10,24 @@ master:
   service:
   service:
     ports:
     ports:
       redis: 6379
       redis: 6379
+  affinity:
+    podAntiAffinityPreset:
+      requiredDuringSchedulingIgnoredDuringExecution:
+        - labelSelector:
+          matchLabels:
+            app.kubernetes.io/name: mariadb
+          topologyKey: kubernetes.io/hostname
 replica:
 replica:
   podLabels:
   podLabels:
     redis: replica
     redis: replica
   replicaCount: 3
   replicaCount: 3
+  affinity:
+    podAntiAffinityPreset:
+      requiredDuringSchedulingIgnoredDuringExecution:
+        - labelSelector:
+          matchLabels:
+            app.kubernetes.io/name: mariadb
+          topologyKey: kubernetes.io/hostname
 metrics:
 metrics:
   enabled: true
   enabled: true
   prometheusRule:
   prometheusRule: