mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-08 04:32:37 +00:00
Rework client.Interface
This commit is contained in:
@@ -26,8 +26,7 @@ import (
|
||||
// for a controller's ReplicaSelector equals the Replicas count.
|
||||
func (c *Client) ControllerHasDesiredReplicas(controller api.ReplicationController) wait.ConditionFunc {
|
||||
return func() (bool, error) {
|
||||
ctx := api.WithNamespace(api.NewContext(), controller.Namespace)
|
||||
pods, err := c.ListPods(ctx, labels.Set(controller.DesiredState.ReplicaSelector).AsSelector())
|
||||
pods, err := c.Pods(controller.Namespace).List(labels.Set(controller.DesiredState.ReplicaSelector).AsSelector())
|
||||
if err != nil {
|
||||
return false, err
|
||||
}
|
||||
|
Reference in New Issue
Block a user