Documentation ¶
Index ¶
- func CreateServiceAccount(p api.PortalProxy, endpointGUID, userGUID string) error
- func DeleteDashboard(p api.PortalProxy, endpointGUID, userGUID string) error
- func DeleteServiceAccount(p api.PortalProxy, endpointGUID, userGUID string) error
- func InstallDashboard(p api.PortalProxy, endpointGUID, userGUID string) error
- func KubeDashboardLogin(c echo.Context, p api.PortalProxy) error
- func KubeDashboardProxy(c echo.Context, p api.PortalProxy, config *rest.Config) error
- func YAMLToJSONWithLabel(body interface{}) ([]byte, error)
- type ServiceInfo
- type StatusResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateServiceAccount ¶
func CreateServiceAccount(p api.PortalProxy, endpointGUID, userGUID string) error
CreateServiceAccount will create a service account for accessing the Kubernetes Dashboard
func DeleteDashboard ¶
func DeleteDashboard(p api.PortalProxy, endpointGUID, userGUID string) error
DeleteDashboard will delete the dashboard from Kubernetes cluster
func DeleteServiceAccount ¶
func DeleteServiceAccount(p api.PortalProxy, endpointGUID, userGUID string) error
DeleteServiceAccount will delete the service account
func InstallDashboard ¶
func InstallDashboard(p api.PortalProxy, endpointGUID, userGUID string) error
InstallDashboard will install the dashboard into a Kubernetes cluster
func KubeDashboardLogin ¶
func KubeDashboardLogin(c echo.Context, p api.PortalProxy) error
KubeDashboardLogin will check and log into the Kubernetes Dashboard then redirect to the Dashboard UI
func KubeDashboardProxy ¶
func KubeDashboardProxy(c echo.Context, p api.PortalProxy, config *rest.Config) error
KubeDashboardProxy proxies a request to the Kube Dash service using the K8S API
func YAMLToJSONWithLabel ¶
Types ¶
type ServiceInfo ¶
type ServiceInfo struct { Namespace string `json:"namespace"` ServiceName string `json:"name"` Scheme string `json:"scheme"` StratosInstalled bool `json:"-"` }
ServiceInfo represents the information for the Dashboard Service that we need to proxy the service
type StatusResponse ¶
type StatusResponse struct { Endpoint string `json:"guid"` Installed bool `json:"installed"` StratosInstalled bool `json:"stratosInstalled"` Running bool `json:"running"` Pod *v1.Pod `json:"pod"` Version string `json:"version"` Service *ServiceInfo `json:"service"` HasToken bool `json:"tokenExists"` ServiceAccont *v1.ServiceAccount `json:"serviceAccount"` Token string `json:"-"` }
StatusResponse is the response from the dashboard status check
func KubeDashboardStatus ¶
func KubeDashboardStatus(p api.PortalProxy, endpointGUID, userGUID string, includeToken bool) (*StatusResponse, error)
KubeDashboardStatus will determine if the specified Kube endpoint has the dashboard installed and ready