Files
rustfs/helm/rustfs/templates/poddisruptionbudget.yaml
T
2026-02-14 10:25:13 +08:00

24 lines
691 B
YAML

{{- if and .Values.pdb.create .Values.mode.distributed.enabled }}
---
apiVersion: policy/v1
kind: PodDisruptionBudget
metadata:
name: {{ include "rustfs.fullname" . }}
namespace: {{ .Release.Namespace }}
labels:
{{- include "rustfs.labels" . | nindent 4 }}
{{- with .Values.commonLabels }}
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- if .Values.pdb.minAvailable }}
minAvailable: {{ .Values.pdb.minAvailable }}
{{- end }}
{{- if and .Values.pdb.maxUnavailable (not .Values.pdb.minAvailable) }}
maxUnavailable: {{ .Values.pdb.maxUnavailable }}
{{- end }}
selector:
matchLabels:
{{- include "rustfs.selectorLabels" . | nindent 6 }}
{{- end }}