add a simple PDB if the replicaCount > 1

This commit is contained in:
Dan 2023-02-17 10:49:37 +00:00 committed by GitHub
parent 4c82f69eef
commit 8af604bdc7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 1 deletions

View File

@ -3,7 +3,7 @@ appVersion: 4.0.2
description: nfs-subdir-external-provisioner is an automatic provisioner that used your *already configured* NFS server, automatically creating Persistent Volumes. description: nfs-subdir-external-provisioner is an automatic provisioner that used your *already configured* NFS server, automatically creating Persistent Volumes.
name: nfs-subdir-external-provisioner name: nfs-subdir-external-provisioner
home: https://github.com/kubernetes-sigs/nfs-subdir-external-provisioner home: https://github.com/kubernetes-sigs/nfs-subdir-external-provisioner
version: 4.0.17 version: 4.0.18
kubeVersion: ">=1.9.0-0" kubeVersion: ">=1.9.0-0"
sources: sources:
- https://github.com/kubernetes-sigs/nfs-subdir-external-provisioner - https://github.com/kubernetes-sigs/nfs-subdir-external-provisioner

View File

@ -0,0 +1,14 @@
{{ if gt .Values.replicaCount 1.0}}
apiVersion: policy/v1
kind: PodDisruptionBudget
metadata:
labels:
{{- include "nfs-subdir-external-provisioner.labels" . | nindent 4 }}
name: {{ template "nfs-subdir-external-provisioner.fullname" . }}
namespace: {{ .Release.Namespace }}
spec:
maxUnavailable: 1
selector:
matchLabels:
{{- include "nfs-subdir-external-provisioner.selectorLabels" . | nindent 6 }}
{{ end }}