Documentation ¶
Index ¶
- func AppUpdateCheck(w http.ResponseWriter, r *http.Request)
- func CORS(w http.ResponseWriter, r *http.Request)
- func CreateAppFromAirgap(w http.ResponseWriter, r *http.Request)
- func DownloadApp(w http.ResponseWriter, r *http.Request)
- func DownloadSnapshotLogs(w http.ResponseWriter, r *http.Request)
- func GenerateNodeJoinCommandMaster(w http.ResponseWriter, r *http.Request)
- func GenerateNodeJoinCommandWorker(w http.ResponseWriter, r *http.Request)
- func GetAppRegistry(w http.ResponseWriter, r *http.Request)
- func Healthz(w http.ResponseWriter, r *http.Request)
- func JSON(w http.ResponseWriter, code int, payload interface{})
- func Login(w http.ResponseWriter, r *http.Request)
- func Metadata(w http.ResponseWriter, r *http.Request)
- func NodeProxy(upstream *httputil.ReverseProxy) func(http.ResponseWriter, *http.Request)
- func NotImplemented(w http.ResponseWriter, r *http.Request)
- func Root(w http.ResponseWriter, r *http.Request)
- func StreamJSON(c *websocket.Conn, payload interface{})
- func SyncLicense(w http.ResponseWriter, r *http.Request)
- func UpdateAppConfig(w http.ResponseWriter, r *http.Request)
- func UpdateAppRegistry(w http.ResponseWriter, r *http.Request)
- func UploadExistingApp(w http.ResponseWriter, r *http.Request)
- type AppUpdateCheckRequest
- type AppUpdateCheckResponse
- type CreateAppFromAirgapRequest
- type CreateAppFromAirgapResponse
- type DatabaseResponse
- type EntitlementResponse
- type GenerateNodeJoinCommandResponse
- type Handlers
- type HealthzResponse
- type LoginRequest
- type LoginResponse
- type MetadataResponse
- type SPAHandler
- type StatusResponse
- type StorageResponse
- type SyncLicenseRequest
- type SyncLicenseResponse
- type UpdateAppConfigRequest
- type UpdateAppConfigResponse
- type UpdateAppRegistryRequest
- type UpdateAppRegistryResponse
- type UploadExistingAppRequest
- type UploadResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AppUpdateCheck ¶ added in v1.13.0
func AppUpdateCheck(w http.ResponseWriter, r *http.Request)
func CreateAppFromAirgap ¶ added in v1.13.0
func CreateAppFromAirgap(w http.ResponseWriter, r *http.Request)
func DownloadApp ¶ added in v1.14.0
func DownloadApp(w http.ResponseWriter, r *http.Request)
func DownloadSnapshotLogs ¶ added in v1.14.0
func DownloadSnapshotLogs(w http.ResponseWriter, r *http.Request)
func GenerateNodeJoinCommandMaster ¶ added in v1.13.0
func GenerateNodeJoinCommandMaster(w http.ResponseWriter, r *http.Request)
func GenerateNodeJoinCommandWorker ¶ added in v1.13.0
func GenerateNodeJoinCommandWorker(w http.ResponseWriter, r *http.Request)
func GetAppRegistry ¶ added in v1.13.0
func GetAppRegistry(w http.ResponseWriter, r *http.Request)
func JSON ¶
func JSON(w http.ResponseWriter, code int, payload interface{})
func NodeProxy ¶
func NodeProxy(upstream *httputil.ReverseProxy) func(http.ResponseWriter, *http.Request)
func NotImplemented ¶
func NotImplemented(w http.ResponseWriter, r *http.Request)
func StreamJSON ¶
func SyncLicense ¶ added in v1.13.0
func SyncLicense(w http.ResponseWriter, r *http.Request)
func UpdateAppConfig ¶ added in v1.13.0
func UpdateAppConfig(w http.ResponseWriter, r *http.Request)
func UpdateAppRegistry ¶ added in v1.13.0
func UpdateAppRegistry(w http.ResponseWriter, r *http.Request)
func UploadExistingApp ¶ added in v1.14.0
func UploadExistingApp(w http.ResponseWriter, r *http.Request)
UploadExistingApp can be used to upload a multipart form file to the existing app This is used in the KOTS CLI when calling kots upload ...
Types ¶
type AppUpdateCheckRequest ¶ added in v1.13.0
type AppUpdateCheckRequest struct { }
type AppUpdateCheckResponse ¶ added in v1.13.0
type AppUpdateCheckResponse struct {
AvailableUpdates int64 `json:"availableUpdates"`
}
type CreateAppFromAirgapRequest ¶ added in v1.13.0
type CreateAppFromAirgapRequest struct { }
type CreateAppFromAirgapResponse ¶ added in v1.13.0
type CreateAppFromAirgapResponse struct { }
type DatabaseResponse ¶
type DatabaseResponse struct {
Connected bool `json:"connected"`
}
type EntitlementResponse ¶ added in v1.13.0
type GenerateNodeJoinCommandResponse ¶ added in v1.13.0
type HealthzResponse ¶
type HealthzResponse struct { Version string `json:"version"` GitSHA string `json:"gitSha"` Status StatusResponse `json:"status"` }
type LoginRequest ¶
type LoginRequest struct {
Password string `json:"password"`
}
type LoginResponse ¶
type LoginResponse struct {
Token string `json:"token"`
}
type MetadataResponse ¶
type SPAHandler ¶
spaHandler implements the http.Handler interface, so we can use it to respond to HTTP requests. The path to the static directory and path to the index file within that static directory are used to serve the SPA in the given static directory.
func (SPAHandler) ServeHTTP ¶
func (h SPAHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)
ServeHTTP inspects the URL path to locate a file within the static dir on the SPA handler. If a file is found, it will be served. If not, the file located at the index path on the SPA handler will be served. This is suitable behavior for serving an SPA (single page application).
type StatusResponse ¶
type StatusResponse struct { Database DatabaseResponse `json:"database"` Storage StorageResponse `json:"storage"` }
type StorageResponse ¶
type StorageResponse struct {
Available bool `json:"available"`
}
type SyncLicenseRequest ¶ added in v1.13.0
type SyncLicenseRequest struct {
LicenseData string `json:"licenseData"`
}
type SyncLicenseResponse ¶ added in v1.13.0
type UpdateAppConfigRequest ¶ added in v1.13.0
type UpdateAppConfigRequest struct { Sequence int64 `json:"sequence"` CreateNewVersion bool `json:"createNewVersion"` ConfigGroups []*kotsv1beta1.ConfigGroup `json:"configGroups"` }
type UpdateAppConfigResponse ¶ added in v1.13.0
type UpdateAppRegistryRequest ¶ added in v1.13.0
type UpdateAppRegistryResponse ¶ added in v1.13.0
type UploadExistingAppRequest ¶ added in v1.14.0
type UploadResponse ¶ added in v1.14.0
type UploadResponse struct {
Slug string `json:"slug"`
}