Create a PodDisruptionBudget for the Cinder CSI controllerplugin (#6385)

pull/6498/head
Steven Reitsma 2020-08-04 14:28:19 +02:00 committed by GitHub
parent bdf0238328
commit f3c17361da
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 0 deletions

View File

@ -41,6 +41,7 @@
- {name: cinder-csi-controllerplugin, file: cinder-csi-controllerplugin.yml}
- {name: cinder-csi-nodeplugin, file: cinder-csi-nodeplugin-rbac.yml}
- {name: cinder-csi-nodeplugin, file: cinder-csi-nodeplugin.yml}
- {name: cinder-csi-poddisruptionbudget, file: cinder-csi-poddisruptionbudget.yml}
register: cinder_csi_manifests
when: inventory_hostname == groups['kube-master'][0]
tags: cinder-csi-driver

View File

@ -0,0 +1,14 @@
apiVersion: policy/v1beta1
kind: PodDisruptionBudget
metadata:
name: cinder-csi-pdb
namespace: kube-system
spec:
{% if cinder_csi_controller_replicas is defined and cinder_csi_controller_replicas > 1 %}
minAvailable: 1
{% else %}
minAvailable: 0
{% endif %}
selector:
matchLabels:
app: csi-cinder-controllerplugin