Create a PodDisruptionBudget for the Cinder CSI controllerplugin (#6385)
parent
bdf0238328
commit
f3c17361da
|
@ -41,6 +41,7 @@
|
||||||
- {name: cinder-csi-controllerplugin, file: cinder-csi-controllerplugin.yml}
|
- {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-rbac.yml}
|
||||||
- {name: cinder-csi-nodeplugin, file: cinder-csi-nodeplugin.yml}
|
- {name: cinder-csi-nodeplugin, file: cinder-csi-nodeplugin.yml}
|
||||||
|
- {name: cinder-csi-poddisruptionbudget, file: cinder-csi-poddisruptionbudget.yml}
|
||||||
register: cinder_csi_manifests
|
register: cinder_csi_manifests
|
||||||
when: inventory_hostname == groups['kube-master'][0]
|
when: inventory_hostname == groups['kube-master'][0]
|
||||||
tags: cinder-csi-driver
|
tags: cinder-csi-driver
|
||||||
|
|
|
@ -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
|
Loading…
Reference in New Issue