mirror of
https://github.com/zalando/postgres-operator.git
synced 2026-10-01 03:22:08 +02:00
fixed case where, no ready label is defined, but node is unscheduable (#1162)
* fixed case where, no ready label is defined, but node is unscheduable
This commit is contained in:
@@ -76,7 +76,7 @@ func (c *Controller) nodeUpdate(prev, cur interface{}) {
|
||||
}
|
||||
|
||||
func (c *Controller) nodeIsReady(node *v1.Node) bool {
|
||||
return (!node.Spec.Unschedulable || util.MapContains(node.Labels, c.opConfig.NodeReadinessLabel) ||
|
||||
return (!node.Spec.Unschedulable || (len(c.opConfig.NodeReadinessLabel) > 0 && util.MapContains(node.Labels, c.opConfig.NodeReadinessLabel)) ||
|
||||
util.MapContains(node.Labels, map[string]string{"master": "true"}))
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user