diff --git a/pkg/registry/pod/rest.go b/pkg/registry/pod/rest.go index e70e28a45c..d8d26969c9 100644 --- a/pkg/registry/pod/rest.go +++ b/pkg/registry/pod/rest.go @@ -321,23 +321,3 @@ func getPodStatus(pod *api.Pod, minions client.MinionInterface) (api.PodStatus, return api.PodWaiting, nil } } - -func (rs *REST) waitForPodRunning(ctx api.Context, pod *api.Pod) (runtime.Object, error) { - for { - podObj, err := rs.Get(ctx, pod.ID) - if err != nil || podObj == nil { - return nil, err - } - podPtr, ok := podObj.(*api.Pod) - if !ok { - // This should really never happen. - return nil, fmt.Errorf("Error %#v is not an api.Pod!", podObj) - } - switch podPtr.CurrentState.Status { - case api.PodRunning, api.PodTerminated: - return pod, nil - default: - time.Sleep(rs.podPollPeriod) - } - } -}