Documentation ¶
Index ¶
- Variables
- func TryLogin(kubeconfigPath string) (*k8s.Clientset, *routeClient.RouteV1Client, error)
- type ContainerLogError
- type GrafanaDatasource
- type GrafanaDatasourceResponse
- type GrafanaSettings
- type OpenSockets
- type ProwInfo
- type ProwJSON
- type RQuotaStatus
- type ServerSettings
- func (s *ServerSettings) AddOrUpdateWS(conn *websocket.Conn)
- func (s *ServerSettings) CleanupOldDeployements(ctx context.Context)
- func (s *ServerSettings) GetResourceQuota(ctx context.Context) error
- func (s *ServerSettings) HandleStatusViaWS(c *gin.Context)
- func (s *ServerSettings) RemoveWS(conn *websocket.Conn)
- func (s *ServerSettings) WatchResourceQuota(ctx context.Context)
- type WSMessage
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrorContainerLog = errors.New("failed to start prometheus")
)
Functions ¶
func TryLogin ¶
func TryLogin(kubeconfigPath string) (*k8s.Clientset, *routeClient.RouteV1Client, error)
TryLogin returns k8s clientset and route client
Types ¶
type ContainerLogError ¶
type GrafanaDatasource ¶
type GrafanaDatasource struct { Name string `json:"name"` Type string `json:"type"` URL string `json:"url"` Access string `json:"access"` BasicAuth bool `json:"basicAuth"` }
GrafanaDatasource represents a datasource to be created
type GrafanaDatasourceResponse ¶
type GrafanaDatasourceResponse struct { DataSource struct { ID int `json:"id"` } `json:"datasource"` }
GrafanaDatasourceResponse represents response from grafana
type GrafanaSettings ¶
type GrafanaSettings struct { URL string `json:"url"` Token string `json:"token"` Cookie string `json:"cookie"` }
GrafanaSettings stores grafana config
type OpenSockets ¶
type ProwJSON ¶
type ProwJSON struct {
Timestamp int `json:"timestamp"`
}
ProwJSON stores test start / finished timestamp
type RQuotaStatus ¶
RQuotaStatus stores ResourceQuota info
type ServerSettings ¶
type ServerSettings struct { K8sClient *k8s.Clientset RouteClient *routeClient.RouteV1Client Namespace string RQuotaName string RQStatus *RQuotaStatus Conns *OpenSockets Datasources map[string]int Grafana *GrafanaSettings }
ServerSettings stores info about the server
func (*ServerSettings) AddOrUpdateWS ¶
func (s *ServerSettings) AddOrUpdateWS(conn *websocket.Conn)
func (*ServerSettings) CleanupOldDeployements ¶
func (s *ServerSettings) CleanupOldDeployements(ctx context.Context)
CleanupOldDeployements periodically removes old deployments
func (*ServerSettings) GetResourceQuota ¶
func (s *ServerSettings) GetResourceQuota(ctx context.Context) error
GetResourceQuota updates current resource quota setting
func (*ServerSettings) HandleStatusViaWS ¶
func (s *ServerSettings) HandleStatusViaWS(c *gin.Context)
HandleStatusViaWS reads websocket events and runs actions
func (*ServerSettings) RemoveWS ¶
func (s *ServerSettings) RemoveWS(conn *websocket.Conn)
func (*ServerSettings) WatchResourceQuota ¶
func (s *ServerSettings) WatchResourceQuota(ctx context.Context)
WatchResourceQuota passes RQ updates from k8s to UI
Click to show internal directories.
Click to hide internal directories.