mirror of
https://github.com/zalando/postgres-operator.git
synced 2026-10-18 08:06:55 +02:00
add missing master matchLabel for the PDB (#144)
This commit is contained in:
@@ -602,6 +602,7 @@ func (c *Cluster) generatePodDisruptionBudget() *policybeta1.PodDisruptionBudget
|
|||||||
minAvailable := intstr.FromInt(1)
|
minAvailable := intstr.FromInt(1)
|
||||||
matchLabels := c.OpConfig.ClusterLabels
|
matchLabels := c.OpConfig.ClusterLabels
|
||||||
matchLabels[c.OpConfig.ClusterNameLabel] = c.Name
|
matchLabels[c.OpConfig.ClusterNameLabel] = c.Name
|
||||||
|
matchLabels[c.OpConfig.PodRoleLabel] = string(Master)
|
||||||
|
|
||||||
return &policybeta1.PodDisruptionBudget{
|
return &policybeta1.PodDisruptionBudget{
|
||||||
ObjectMeta: metav1.ObjectMeta{
|
ObjectMeta: metav1.ObjectMeta{
|
||||||
|
|||||||
Reference in New Issue
Block a user