handlers

package
v0.0.0-...-f4dd878 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 12, 2024 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddClusterNode

func AddClusterNode(w http.ResponseWriter, r *http.Request)

func AddNodeJoinCommand

func AddNodeJoinCommand(w http.ResponseWriter, r *http.Request)

func AddNodeUpgradeCommand

func AddNodeUpgradeCommand(w http.ResponseWriter, r *http.Request)

func DequeueInstance

func DequeueInstance(w http.ResponseWriter, r *http.Request)

func DequeueInstanceWithRef

func DequeueInstanceWithRef(w http.ResponseWriter, r *http.Request)

func FinishInstance

func FinishInstance(w http.ResponseWriter, r *http.Request)

func GetInstanceLogs

func GetInstanceLogs(w http.ResponseWriter, r *http.Request)

func GetInstanceSonobuoyResults

func GetInstanceSonobuoyResults(w http.ResponseWriter, r *http.Request)

func GetNodeJoinCommand

func GetNodeJoinCommand(w http.ResponseWriter, r *http.Request)

func GetNodeLogs

func GetNodeLogs(w http.ResponseWriter, r *http.Request)

func GetNodeStatus

func GetNodeStatus(w http.ResponseWriter, r *http.Request)

func GetNodeUpgradeCommand

func GetNodeUpgradeCommand(w http.ResponseWriter, r *http.Request)

func GetRun

func GetRun(w http.ResponseWriter, r *http.Request)

func GetRunAddons

func GetRunAddons(w http.ResponseWriter, r *http.Request)

func GetRunStatus

func GetRunStatus(w http.ResponseWriter, r *http.Request)

func Healthz

func Healthz(w http.ResponseWriter, r *http.Request)

func InstanceBundle

func InstanceBundle(passpharse string) func(http.ResponseWriter, *http.Request)

func InstanceLogs

func InstanceLogs(w http.ResponseWriter, r *http.Request)

func InstanceSonobuoyResults

func InstanceSonobuoyResults(w http.ResponseWriter, r *http.Request)

func JSON

func JSON(w http.ResponseWriter, code int, payload interface{})

func ListRuns

func ListRuns(w http.ResponseWriter, r *http.Request)

func NodeLogs

func NodeLogs(w http.ResponseWriter, r *http.Request)

func RunnerStatus

func RunnerStatus(w http.ResponseWriter, r *http.Request)

func RunningInstance

func RunningInstance(w http.ResponseWriter, r *http.Request)

func SkipInstances

func SkipInstances(w http.ResponseWriter, r *http.Request)

SkipInstances will skip all instances by ref ID. Instances will show up in the UI as "Skipped".

func StartInstance

func StartInstance(w http.ResponseWriter, r *http.Request)

func StartRef

func StartRef(w http.ResponseWriter, r *http.Request)

func UpdateNodeStatus

func UpdateNodeStatus(w http.ResponseWriter, r *http.Request)

func WebConfig

func WebConfig(w http.ResponseWriter, r *http.Request)

Types

type ClusterNodeRequest

type ClusterNodeRequest struct {
	NodeId   string `json:"nodeId"`
	NodeType string `json:"nodeType"`
	Status   string `json:"status"`
}

type ConfigResponse

type ConfigResponse struct {
}

type CreateJoinCommandRequest

type CreateJoinCommandRequest struct {
	PrimaryJoin   string `json:"primaryJoin"`
	SecondaryJoin string `json:"secondaryJoin"`
}

type CreateNodeUpgradeRequest

type CreateNodeUpgradeRequest struct {
	Command string `json:"command"`
}

type DequeueInstanceResponse

type DequeueInstanceResponse struct {
	ID                string `json:"id"`
	NumPrimaryNodes   int    `json:"numPrimaryNodes"`
	NumSecondaryNodes int    `json:"numSecondaryNodes"`
	Memory            string `json:"memory"`
	CPU               string `json:"cpu"`

	OperatingSystemName    string `json:"operatingSystemName"`
	OperatingSystemVersion string `json:"operatingSystemVersion"`
	OperatingSystemImage   string `json:"operatingSystemImage"`
	OperatingSystemPreInit string `json:"operatingSystemPreInit"`

	KurlYAML          string `json:"kurlYaml"`
	KurlURL           string `json:"kurlUrl"`
	KurlFlags         string `json:"kurlFlags"`
	UpgradeURL        string `json:"upgradeUrl"`
	SupportbundleYAML string `json:"supportbundleYaml"`
	PreInstallScript  string `json:"preInstallScript"`
	PostInstallScript string `json:"postInstallScript"`
	PostUpgradeScript string `json:"postUpgradeScript"`
	KurlRef           string `json:"kurlRef"`
}

type FinishInstanceRequest

type FinishInstanceRequest struct {
	Success       bool   `json:"success"`
	FailureReason string `json:"failureReason"`
}

type GetInstanceLogsResponse

type GetInstanceLogsResponse struct {
	Logs string `json:"logs"`
}

type GetInstanceSonobuoyResultsResponse

type GetInstanceSonobuoyResultsResponse struct {
	Results string `json:"results"`
}

type GetJoinCommandResponse

type GetJoinCommandResponse struct {
	PrimaryJoin   string `json:"primaryJoin"`
	SecondaryJoin string `json:"secondaryJoin"`
}

type GetNodeLogsResponse

type GetNodeLogsResponse struct {
	Logs string `json:"logs"`
}

type GetNodeStatusResponse

type GetNodeStatusResponse struct {
	Status string `json:"status"`
}

type GetNodeUpgradeResponse

type GetNodeUpgradeResponse struct {
	Command string `json:"command"`
}

type GetRunAddonsResponse

type GetRunAddonsResponse struct {
	Addons []string `json:"addons"`
}

type GetRunRequest

type GetRunRequest struct {
	PageSize    int               `json:"pageSize"`
	CurrentPage int               `json:"currentPage"`
	Addons      map[string]string `json:"addons"`
}

type GetRunResponse

type GetRunResponse struct {
	Instances    []types.TestInstance `json:"instances"`
	Total        int                  `json:"total"`
	LastStart    *time.Time           `json:"last_start"`
	LastResponse *time.Time           `json:"last_response"`
	SuccessCount int64                `json:"success_count"` // success_count plus failure_count will not always equal total due to unsupported instances
	FailureCount int64                `json:"failure_count"`
}

type GetStatusResponse

type GetStatusResponse struct {
	IsSuccess bool `json:"isSuccess"`
}

type Handlers

type Handlers struct {
}

type HealthzResponse

type HealthzResponse struct {
	IsAlive bool `json:"is_alive"`
}

type ListRunsResponse

type ListRunsResponse struct {
	Runs  []types.TestRun `json:"runs"`
	Total int             `json:"total"`
}

type PlannedInstance

type PlannedInstance struct {
	ID                string
	TestID            string
	TestName          string
	Priority          int
	NumPrimaryNodes   int
	NumSecondaryNodes int
	Memory            string
	CPU               string

	KurlYAML  string
	KurlURL   string
	KurlFlags string

	UpgradeYAML string
	UpgradeURL  string

	SupportbundleYAML string

	PreInstallScript  string
	PostInstallScript string
	PostUpgradeScript string

	OperatingSystemName    string
	OperatingSystemVersion string
	OperatingSystemImage   string
	OperatingSystemPreInit string

	IsUnsupported bool
}

type RunnerStatusRequest

type RunnerStatusRequest struct {
	FreeCPU      float64 `json:"freeCPU"`
	FreeRAM      float64 `json:"freeRAM"`
	RunningTests float64 `json:"runningTests"`
	Hostname     string  `json:"hostname"`
}

type StartInstanceRequest

type StartInstanceRequest struct {
	OSName    string `json:"osName"`
	OSVersion string `json:"osVersion"`
	OSImage   string `json:"osImage"`

	Memory string `json:"memory"`
	CPU    string `json:"cpu"`

	KurlRef  string `json:"kurlRef"`
	KurlSpec string `json:"kurlSpec"`
	KurlURL  string `json:"kurlUrl"`
}

type StartRefRequest

type StartRefRequest struct {
	Overwrite bool              `json:"overwrite"`
	Instances []PlannedInstance `json:"instances"`
}

type StartRefResponse

type StartRefResponse struct {
	Success bool `json:"success"`
}

type StatusUpdateRequest

type StatusUpdateRequest struct {
	Status string `json:"status"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL