mirror of
https://github.com/komodorio/helm-dashboard.git
synced 2026-03-24 03:38:04 +00:00
Improve console message in case no k8s connection possible
This commit is contained in:
@@ -46,7 +46,7 @@ func (s *Server) StartServer(ctx context.Context, cancel context.CancelFunc) (st
|
||||
|
||||
err = s.detectClusterMode(data)
|
||||
if err != nil {
|
||||
return "", nil, err
|
||||
return "", nil, errorx.Decorate(err, "Failed to detect cluster mode")
|
||||
}
|
||||
|
||||
go checkUpgrade(data.StatusInfo)
|
||||
@@ -80,7 +80,7 @@ func (s *Server) detectClusterMode(data *objects.DataLayer) error {
|
||||
}
|
||||
ns, err := app.K8s.GetNameSpaces()
|
||||
if err != nil { // no point in continuing without kubectl context and k8s connection
|
||||
return err
|
||||
return errorx.InitializationFailed.Wrap(err, "No k8s cluster connection")
|
||||
}
|
||||
log.Debugf("Got %d namespaces listed", len(ns.Items))
|
||||
data.StatusInfo.ClusterMode = true
|
||||
|
||||
Reference in New Issue
Block a user