mirror of
https://github.com/niusmallnan/steve.git
synced 2025-09-10 17:39:37 +00:00
Add dashboard to steve
This commit is contained in:
@@ -10,6 +10,7 @@ import (
|
||||
"github.com/rancher/steve/pkg/client"
|
||||
"github.com/rancher/steve/pkg/clustercache"
|
||||
schemacontroller "github.com/rancher/steve/pkg/controllers/schema"
|
||||
"github.com/rancher/steve/pkg/dashboard"
|
||||
"github.com/rancher/steve/pkg/schema"
|
||||
"github.com/rancher/steve/pkg/schemaserver/types"
|
||||
"github.com/rancher/steve/pkg/server/handler"
|
||||
@@ -87,6 +88,10 @@ func setup(ctx context.Context, server *Server) (http.Handler, *schema.Collectio
|
||||
return sync()
|
||||
})
|
||||
|
||||
if server.DashboardURL != nil && server.DashboardURL() != "" {
|
||||
handler = dashboard.Route(handler, server.DashboardURL)
|
||||
}
|
||||
|
||||
return handler, sf, nil
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user