Documentation ¶
Index ¶
- func Install(parent iris.Party)
- type ApiGroupOption
- type ApiResourceOption
- type Cluster
- type CreateRepo
- type ExtraClusterInfo
- type Handler
- func (h *Handler) AddCLusterRepo() iris.Handler
- func (h *Handler) CreateCluster() iris.Handler
- func (h *Handler) CreateClusterMember() iris.Handler
- func (h *Handler) CreateClusterRole() iris.Handler
- func (h *Handler) DeleteCluster() iris.Handler
- func (h *Handler) DeleteClusterMember() iris.Handler
- func (h *Handler) DeleteClusterRepo() iris.Handler
- func (h *Handler) DeleteClusterRole() iris.Handler
- func (h *Handler) GetCluster() iris.Handler
- func (h *Handler) GetClusterMember() iris.Handler
- func (h *Handler) ListApiGroupResources() iris.Handler
- func (h *Handler) ListApiGroups() iris.Handler
- func (h *Handler) ListClusterMembers() iris.Handler
- func (h *Handler) ListClusterRepos() iris.Handler
- func (h *Handler) ListClusterReposDetail() iris.Handler
- func (h *Handler) ListClusterRoles() iris.Handler
- func (h *Handler) ListClusters() iris.Handler
- func (h *Handler) ListNamespace() iris.Handler
- func (h *Handler) LoggingHandler() iris.Handler
- func (h *Handler) NodeTerminalSessionHandler() iris.Handler
- func (h *Handler) SearchClusters() iris.Handler
- func (h *Handler) TerminalSessionHandler() iris.Handler
- func (h *Handler) UpdateCluster() iris.Handler
- func (h *Handler) UpdateClusterMember() iris.Handler
- func (h *Handler) UpdateClusterRole() iris.Handler
- type Member
- type NamespaceRoles
- type Privilege
- type Repo
- type TerminalResponse
- type UpdateCluster
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type ApiGroupOption ¶ added in v1.6.0
type ApiGroupOption struct { Group string `json:"group"` Resources []ApiResourceOption `json:"resources"` }
type ApiResourceOption ¶ added in v1.6.0
type Cluster ¶
type Cluster struct { v1Cluster.Cluster KeyDataStr string `json:"keyDataStr"` CertDataStr string `json:"certDataStr"` CaDataStr string `json:"caDataStr"` ConfigFileContentStr string `json:"configContentStr"` Accessable bool `json:"accessable"` MemberCount int `json:"memberCount"` ExtraClusterInfo ExtraClusterInfo `json:"extraClusterInfo"` }
type CreateRepo ¶ added in v1.3.0
type ExtraClusterInfo ¶
type ExtraClusterInfo struct { TotalNodeNum int `json:"totalNodeNum"` ReadyNodeNum int `json:"readyNodeNum"` CPUAllocatable float64 `json:"cpuAllocatable"` CPURequested float64 `json:"cpuRequested"` MemoryAllocatable float64 `json:"memoryAllocatable"` MemoryRequested float64 `json:"memoryRequested"` Health bool `json:"health"` Message string `json:"message"` }
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
func NewHandler ¶
func NewHandler() *Handler
func (*Handler) AddCLusterRepo ¶ added in v1.3.0
func (h *Handler) AddCLusterRepo() iris.Handler
Create Cluster Repo @Tags clusters @Summary Create Cluster Repo @Description Create Cluster Repo @Accept json @Produce json @Param cluster path string true "集群名称" @Param request body CreateRepo true "request" @Success 200 {object} CreateRepo @Security ApiKeyAuth @Router /clusters/{cluster}/repos [post]
func (*Handler) CreateCluster ¶
func (h *Handler) CreateCluster() iris.Handler
Create Cluster @Tags clusters @Summary Create Cluster @Description Create Cluster @Accept json @Produce json @Param request body Cluster true "request" @Success 200 {object} Cluster @Security ApiKeyAuth @Router /clusters [post]
func (*Handler) CreateClusterMember ¶
func (h *Handler) CreateClusterMember() iris.Handler
Create Cluster Member @Tags clusters @Summary Create Cluster Member @Description Create Cluster Member @Accept json @Produce json @Param cluster path string true "集群名称" @Param request body Member true "request" @Success 200 {object} Member @Security ApiKeyAuth @Router /clusters/{cluster}/members [post]
func (*Handler) CreateClusterRole ¶
func (h *Handler) CreateClusterRole() iris.Handler
Create Cluster Role @Tags clusters @Summary Create Cluster Role @Description Create Cluster Role @Accept json @Produce json @Param cluster path string true "集群名称" @Param request body rbacV1.ClusterRole true "request" @Success 200 {object} rbacV1.ClusterRole @Security ApiKeyAuth @Router /clusters/{cluster}/clusterroles [post]
func (*Handler) DeleteCluster ¶
func (h *Handler) DeleteCluster() iris.Handler
Delete Cluster @Tags clusters @Summary Delete cluster by name @Description Delete cluster by name @Accept json @Produce json @Param name path string true "集群名称" @Success 200 {object} v1Cluster.Cluster @Security ApiKeyAuth @Router /clusters/{name} [delete]
func (*Handler) DeleteClusterMember ¶
func (h *Handler) DeleteClusterMember() iris.Handler
Delete ClusterMember @Tags clusters @Summary Delete clusterMember by name @Description Delete clusterMember by name @Accept json @Produce json @Param cluster path string true "集群名称" @Param members path string true "成员名称" @Success 200 {number} 200 @Security ApiKeyAuth @Router /clusters/{cluster}/members/{member} [delete]
func (*Handler) DeleteClusterRepo ¶ added in v1.3.0
func (h *Handler) DeleteClusterRepo() iris.Handler
Delete ClusterRepo @Tags clusters @Summary Delete clusterRepo by name @Description Delete clusterRepo by name @Accept json @Produce json @Param cluster path string true "集群名称" @Param repo path string true "镜像仓库名称" @Success 200 {number} 200 @Security ApiKeyAuth @Router /clusters/{cluster}/repos/{repo} [delete]
func (*Handler) DeleteClusterRole ¶
func (h *Handler) DeleteClusterRole() iris.Handler
Delete ClusterRole @Tags clusters @Summary Delete clusterRole by name @Description Delete clusterRole by name @Accept json @Produce json @Param cluster path string true "集群名称" @Param clusterrole path string true "权限名称" @Success 200 {number} 200 @Security ApiKeyAuth @Router /clusters/{cluster}/clusterroles/{clusterrole} [delete]
func (*Handler) GetCluster ¶
func (h *Handler) GetCluster() iris.Handler
Get Cluster @Tags clusters @Summary Get cluster by name @Description Get cluster by name @Accept json @Produce json @Param name path string true "集群名称" @Success 200 {object} v1Cluster.Cluster @Security ApiKeyAuth @Router /clusters/{name} [get]
func (*Handler) GetClusterMember ¶
func (h *Handler) GetClusterMember() iris.Handler
Get Cluster Member By name @Tags clusters @Summary Get Cluster Member By name @Description Get Cluster Member By name @Accept json @Produce json @Param cluster path string true "集群名称" @Param member path string true "成员名称" @Success 200 {object} Member @Security ApiKeyAuth @Router /clusters/{cluster}/members/{member} [get]
func (*Handler) ListApiGroupResources ¶
func (h *Handler) ListApiGroupResources() iris.Handler
func (*Handler) ListApiGroups ¶
func (h *Handler) ListApiGroups() iris.Handler
func (*Handler) ListClusterMembers ¶
func (h *Handler) ListClusterMembers() iris.Handler
List ClusterMembers @Tags clusters @Summary List all ClusterMembers @Description List all ClusterMembers @Accept json @Produce json @Param cluster path string true "集群名称" @Success 200 {object} []Member @Security ApiKeyAuth @Router /clusters/{cluster}/members [get]
func (*Handler) ListClusterRepos ¶ added in v1.3.0
func (h *Handler) ListClusterRepos() iris.Handler
List ClusterRepos @Tags clusters @Summary List all clusterRepos @Description List all clusterRepos @Accept json @Produce json @Param cluster path string true "集群名称" @Success 200 {object} []clusterrepo.ClusterRepo @Security ApiKeyAuth @Router /clusters/{cluster}/repos [get]
func (*Handler) ListClusterReposDetail ¶ added in v1.3.0
func (h *Handler) ListClusterReposDetail() iris.Handler
Get ClusterRepo Detail @Tags clusters @Summary Get ClusterRepo Detail @Description Get ClusterRepo Detail @Accept json @Produce json @Param cluster path string true "集群名称" @Success 200 {object} []imagerepo.ImageRepo @Security ApiKeyAuth @Router /clusters/{cluster}/repos [get]
func (*Handler) ListClusterRoles ¶
func (h *Handler) ListClusterRoles() iris.Handler
List ClusterRoles @Tags clusters @Summary List all clusterRoles @Description List all clusterRoles @Accept json @Produce json @Param cluster path string true "集群名称" @Success 200 {object} []rbacV1.ClusterRole @Security ApiKeyAuth @Router /clusters/{cluster}/clusterroles [get]
func (*Handler) ListClusters ¶
func (h *Handler) ListClusters() iris.Handler
List Clusters @Tags clusters @Summary List all clusters @Description List all clusters @Accept json @Produce json @Success 200 {object} []v1Cluster.Cluster @Security ApiKeyAuth @Router /clusters [get]
func (*Handler) ListNamespace ¶
func (h *Handler) ListNamespace() iris.Handler
func (*Handler) LoggingHandler ¶
func (h *Handler) LoggingHandler() iris.Handler
func (*Handler) NodeTerminalSessionHandler ¶ added in v1.9.0
func (h *Handler) NodeTerminalSessionHandler() iris.Handler
node shell
func (*Handler) SearchClusters ¶
func (h *Handler) SearchClusters() iris.Handler
func (*Handler) TerminalSessionHandler ¶
func (h *Handler) TerminalSessionHandler() iris.Handler
func (*Handler) UpdateCluster ¶ added in v1.2.0
func (h *Handler) UpdateCluster() iris.Handler
Update Cluster @Tags clusters @Summary Update cluster by name @Description Update cluster by name @Accept json @Produce json @Param request body UpdateCluster true "request" @Param name path string true "集群名称" @Success 200 {object} UpdateCluster @Security ApiKeyAuth @Router /clusters/{name} [put]
func (*Handler) UpdateClusterMember ¶
func (h *Handler) UpdateClusterMember() iris.Handler
Update Cluster Member @Tags clusters @Summary Update Cluster Member @Description Update Cluster Member @Accept json @Produce json @Param cluster path string true "集群名称" @Param member path string true "成员名称" @Param request body Member true "request" @Success 200 {object} Member @Security ApiKeyAuth @Router /clusters/{cluster}/members/{member} [put]
func (*Handler) UpdateClusterRole ¶
func (h *Handler) UpdateClusterRole() iris.Handler
Update Cluster Role @Tags clusters @Summary Update Cluster Role @Description Update Cluster Role @Accept json @Produce json @Param cluster path string true "集群名称" @Param clusterrole path string true "权限名称" @Param request body rbacV1.ClusterRole true "request" @Success 200 {object} rbacV1.ClusterRole @Security ApiKeyAuth @Router /clusters/{cluster}/clusterroles/{clusterrole} [put]
type NamespaceRoles ¶
type Repo ¶ added in v1.3.0
type Repo struct {
V1ClusterRepo.ClusterRepo
}
type TerminalResponse ¶
type TerminalResponse struct {
ID string `json:"id"`
}
type UpdateCluster ¶ added in v1.2.0
type UpdateCluster struct { Mode string `json:"mode"` ApiServer string `json:"apiServer"` Token string `json:"token"` KeyData string `json:"keyData"` CertData string `json:"certData"` ConfigFileContent string `json:"configFileContent"` WithLabel bool `json:"withLabel"` Labels []string `json:"labels"` }