oc-k8s/opencloud/charts/loki/templates/read/poddisruptionbudget-read.yaml

16 lines
476 B
YAML
Raw Permalink Normal View History

2024-12-16 14:55:43 +01:00
{{- $isSimpleScalable := eq (include "loki.deployment.isScalable" .) "true" -}}
{{- if and $isSimpleScalable (gt (int .Values.read.replicas) 1) }}
apiVersion: policy/v1
kind: PodDisruptionBudget
metadata:
name: {{ include "loki.readFullname" . }}
namespace: {{ $.Release.Namespace }}
labels:
{{- include "loki.readLabels" . | nindent 4 }}
spec:
selector:
matchLabels:
{{- include "loki.readSelectorLabels" . | nindent 6 }}
maxUnavailable: 1
{{- end }}