From 723e729659f804c6aea8799261dd3eaed6ea9363 Mon Sep 17 00:00:00 2001 From: Edward Welch Date: Thu, 14 Mar 2024 00:27:54 +0000 Subject: [PATCH] allow adding per zone pod annotations. Signed-off-by: Edward Welch --- .../ingester/statefulset-ingester-zone-a.yaml | 3 +++ .../ingester/statefulset-ingester-zone-b.yaml | 3 +++ .../ingester/statefulset-ingester-zone-c.yaml | 3 +++ production/helm/loki/values.yaml | 12 +++++++++--- 4 files changed, 18 insertions(+), 3 deletions(-) diff --git a/production/helm/loki/templates/ingester/statefulset-ingester-zone-a.yaml b/production/helm/loki/templates/ingester/statefulset-ingester-zone-a.yaml index 4a11f88196d8..69b2fcaf9a51 100644 --- a/production/helm/loki/templates/ingester/statefulset-ingester-zone-a.yaml +++ b/production/helm/loki/templates/ingester/statefulset-ingester-zone-a.yaml @@ -52,6 +52,9 @@ spec: {{- with .Values.ingester.podAnnotations }} {{- toYaml . | nindent 8 }} {{- end }} + {{- with .Values.ingester.zoneAwareReplication.zoneA.podAnnotations }} + {{- toYaml . | nindent 8 }} + {{- end }} labels: {{- include "loki.ingesterSelectorLabels" . | nindent 8 }} app.kubernetes.io/part-of: memberlist diff --git a/production/helm/loki/templates/ingester/statefulset-ingester-zone-b.yaml b/production/helm/loki/templates/ingester/statefulset-ingester-zone-b.yaml index 9919124a7287..60bd81f0c4a0 100644 --- a/production/helm/loki/templates/ingester/statefulset-ingester-zone-b.yaml +++ b/production/helm/loki/templates/ingester/statefulset-ingester-zone-b.yaml @@ -52,6 +52,9 @@ spec: {{- with .Values.ingester.podAnnotations }} {{- toYaml . | nindent 8 }} {{- end }} + {{- with .Values.ingester.zoneAwareReplication.zoneB.podAnnotations }} + {{- toYaml . | nindent 8 }} + {{- end }} labels: {{- include "loki.ingesterSelectorLabels" . | nindent 8 }} app.kubernetes.io/part-of: memberlist diff --git a/production/helm/loki/templates/ingester/statefulset-ingester-zone-c.yaml b/production/helm/loki/templates/ingester/statefulset-ingester-zone-c.yaml index d0fee7513691..dcb1a0d4baee 100644 --- a/production/helm/loki/templates/ingester/statefulset-ingester-zone-c.yaml +++ b/production/helm/loki/templates/ingester/statefulset-ingester-zone-c.yaml @@ -52,6 +52,9 @@ spec: {{- with .Values.ingester.podAnnotations }} {{- toYaml . | nindent 8 }} {{- end }} + {{- with .Values.ingester.zoneAwareReplication.zoneC.podAnnotations }} + {{- toYaml . | nindent 8 }} + {{- end }} labels: {{- include "loki.ingesterSelectorLabels" . | nindent 8 }} app.kubernetes.io/part-of: memberlist diff --git a/production/helm/loki/values.yaml b/production/helm/loki/values.yaml index 54f2dc084ec1..0da4b885756f 100644 --- a/production/helm/loki/values.yaml +++ b/production/helm/loki/values.yaml @@ -1757,22 +1757,28 @@ ingester: nodeSelector: null # -- optionally define extra affinity rules, by default different zones are not allowed to schedule on the same host extraAffinity: {} - # -- Specific annotations to add to zone A + # -- Specific annotations to add to zone A statefulset annotations: {} + # -- Specific annotations to add to zone A pods + podAnnotations: {} zoneB: # -- optionally define a node selector for this zone nodeSelector: null # -- optionally define extra affinity rules, by default different zones are not allowed to schedule on the same host extraAffinity: {} - # -- Specific annotations to add to zone B + # -- Specific annotations to add to zone B statefulset annotations: {} + # -- Specific annotations to add to zone B pods + podAnnotations: {} zoneC: # -- optionally define a node selector for this zone nodeSelector: null # -- optionally define extra affinity rules, by default different zones are not allowed to schedule on the same host extraAffinity: {} - # -- Specific annotations to add to zone C + # -- Specific annotations to add to zone C statefulset annotations: {} + # -- Specific annotations to add to zone C pods + podAnnotations: {} # -- The migration block allows migrating non zone aware ingesters to zone aware ingesters. migration: enabled: false