fix pod disruption budget labels (#146)

This commit is contained in:
Murat Kabilov 2017-10-20 15:01:51 +02:00 committed by Jan Mussler
parent 39200ba8d4
commit c17aabb642
1 changed files with 1 additions and 4 deletions

View File

@ -600,9 +600,6 @@ func (c *Cluster) generateCloneEnvironment(description *spec.CloneDescription) [
func (c *Cluster) generatePodDisruptionBudget() *policybeta1.PodDisruptionBudget {
minAvailable := intstr.FromInt(1)
matchLabels := c.OpConfig.ClusterLabels
matchLabels[c.OpConfig.ClusterNameLabel] = c.Name
matchLabels[c.OpConfig.PodRoleLabel] = string(Master)
return &policybeta1.PodDisruptionBudget{
ObjectMeta: metav1.ObjectMeta{
@ -612,7 +609,7 @@ func (c *Cluster) generatePodDisruptionBudget() *policybeta1.PodDisruptionBudget
Spec: policybeta1.PodDisruptionBudgetSpec{
MinAvailable: &minAvailable,
Selector: &metav1.LabelSelector{
MatchLabels: matchLabels,
MatchLabels: c.roleLabelsSet(Master),
},
},
}