diff --git a/pkg/dashboard/api.go b/pkg/dashboard/api.go index ac93b4ed..e2b26245 100644 --- a/pkg/dashboard/api.go +++ b/pkg/dashboard/api.go @@ -73,7 +73,7 @@ func configureRoutes(abortWeb utils.ControlChan, data *subproc.DataLayer, api *g api.GET("/status", func(c *gin.Context) { c.Header("X-Application-Name", "Helm Dashboard by Komodor.io") // to identify ourselves by ourselves - c.IndentedJSON(http.StatusOK, data.VersionInfo) + c.IndentedJSON(http.StatusOK, data.StatusInfo) }) configureHelms(api.Group("/api/helm"), data) diff --git a/pkg/dashboard/server.go b/pkg/dashboard/server.go index e550f27e..2402072e 100644 --- a/pkg/dashboard/server.go +++ b/pkg/dashboard/server.go @@ -26,11 +26,12 @@ func StartServer(version string, port int, ns string, debug bool, noTracking boo os.Exit(1) // TODO: propagate error instead? } - data.VersionInfo = &subproc.VersionInfo{ - CurVer: version, - Analytics: !noTracking, + data.StatusInfo = &subproc.StatusInfo{ + CurVer: version, + Analytics: !noTracking, + LimitedToNamespace: ns, } - go checkUpgrade(data.VersionInfo) + go checkUpgrade(data.StatusInfo) discoverScanners(&data) @@ -102,7 +103,7 @@ func discoverScanners(data *subproc.DataLayer) { } } -func checkUpgrade(d *subproc.VersionInfo) { +func checkUpgrade(d *subproc.StatusInfo) { url := "https://api.github.com/repos/komodorio/helm-dashboard/releases/latest" type GHRelease struct { Name string `json:"name"` diff --git a/pkg/dashboard/static/index.html b/pkg/dashboard/static/index.html index 3cbd6992..826fbc25 100644 --- a/pkg/dashboard/static/index.html +++ b/pkg/dashboard/static/index.html @@ -90,7 +90,8 @@

Repositories

-

+

REPOSITORY

name-of-repo

@@ -120,6 +121,7 @@

Clusters

+