Skip to content

Commit

Permalink
Merge pull request #5910 from Shubham82/cherry-picked-of-#5776-upstre…
Browse files Browse the repository at this point in the history
…am-cluster-autoscaler-release-1.27

Backport #5776 [cluster-autoscaler] "Change magnum to use control-plane role" into CA1.27
  • Loading branch information
k8s-ci-robot authored Jul 3, 2023
2 parents aa7cefe + 3e0f68a commit cc21718
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,11 @@ func (mcp *magnumCloudProvider) NodeGroupForNode(node *apiv1.Node) (cloudprovide
return nil, nil
}

// Ignore control-plane nodes
if _, found := node.ObjectMeta.Labels["node-role.kubernetes.io/control-plane"]; found {
return nil, nil
}

ngUUID, err := mcp.magnumManager.nodeGroupForNode(node)
if err != nil {
return nil, fmt.Errorf("error finding node group UUID for node %s: %v", node.Spec.ProviderID, err)
Expand Down

0 comments on commit cc21718

Please sign in to comment.