Skip to content

Commit

Permalink
improving error message for service not in default namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
rbrishabh committed Sep 11, 2019
1 parent f36c5d8 commit 8bb5b30
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/minikube/service/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ func CheckService(namespace string, service string) error {
svc, err := client.Services(namespace).Get(service, meta.GetOptions{})
if err != nil {
return &retry.RetriableError{
Err: errors.Wrapf(err, "Error getting service %s", service),
Err: errors.Wrapf(err),
}
}
if len(svc.Spec.Ports) == 0 {
Expand Down Expand Up @@ -266,7 +266,7 @@ func WaitAndMaybeOpenService(api libmachine.API, namespace string, service strin
chkSVC := func() error { return CheckService(namespace, service) }

if err := retry.Expo(chkSVC, time.Duration(interval)*time.Second, time.Duration(wait)*time.Second); err != nil {
return errors.Wrapf(err, "Could not find finalized endpoint being pointed to by %s", service)
return errors.Wrapf(err, "Service %s was not found in default namespace, please try again with 'minikube service %s -n Y'", service, service)
}

urls, err := GetServiceURLsForService(api, namespace, service, urlTemplate)
Expand Down

0 comments on commit 8bb5b30

Please sign in to comment.