Documentation
¶
Index ¶
- func RegisterRoutes(r chi.Router)
- type Controller
- func (cc *Controller) BatchRestart(c *response.Context)
- func (cc *Controller) BatchRestore(c *response.Context)
- func (cc *Controller) BatchStop(c *response.Context)
- func (cc *Controller) HPA(c *response.Context)
- func (cc *Controller) History(c *response.Context)
- func (cc *Controller) Restart(c *response.Context)
- func (cc *Controller) Scale(c *response.Context)
- func (cc *Controller) Undo(c *response.Context)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterRoutes ¶ added in v0.0.145
Types ¶
type Controller ¶ added in v0.0.145
type Controller struct{}
func (*Controller) BatchRestart ¶ added in v0.0.145
func (cc *Controller) BatchRestart(c *response.Context)
@Summary 批量重启StatefulSet @Security BearerAuth @Param cluster query string true "集群名称" @Param name_list body []string true "StatefulSet名称列表" @Param ns_list body []string true "命名空间列表" @Success 200 {object} string @Router /k8s/cluster/{cluster}/statefulset/batch/restart [post]
func (*Controller) BatchRestore ¶ added in v0.0.145
func (cc *Controller) BatchRestore(c *response.Context)
@Summary 批量恢复StatefulSet @Security BearerAuth @Param cluster query string true "集群名称" @Param name_list body []string true "StatefulSet名称列表" @Param ns_list body []string true "命名空间列表" @Success 200 {object} string @Router /k8s/cluster/{cluster}/statefulset/batch/restore [post]
func (*Controller) BatchStop ¶ added in v0.0.145
func (cc *Controller) BatchStop(c *response.Context)
@Summary 批量停止StatefulSet @Security BearerAuth @Param cluster query string true "集群名称" @Param name_list body []string true "StatefulSet名称列表" @Param ns_list body []string true "命名空间列表" @Success 200 {object} string @Router /k8s/cluster/{cluster}/statefulset/batch/stop [post]
func (*Controller) HPA ¶ added in v0.0.145
func (cc *Controller) HPA(c *response.Context)
@Summary 获取StatefulSet的HPA列表 @Security BearerAuth @Param cluster query string true "集群名称" @Param ns path string true "命名空间" @Param name path string true "StatefulSet名称" @Success 200 {object} string @Router /k8s/cluster/{cluster}/statefulset/ns/{ns}/name/{name}/hpa [get]
func (*Controller) History ¶ added in v0.0.145
func (cc *Controller) History(c *response.Context)
@Summary 获取StatefulSet滚动历史 @Security BearerAuth @Param cluster query string true "集群名称" @Param ns path string true "命名空间" @Param name path string true "StatefulSet名称" @Success 200 {object} string @Router /k8s/cluster/{cluster}/statefulset/ns/{ns}/name/{name}/rollout/history [get]
func (*Controller) Restart ¶ added in v0.0.145
func (cc *Controller) Restart(c *response.Context)
@Summary 重启StatefulSet @Security BearerAuth @Param cluster query string true "集群名称" @Param ns path string true "命名空间" @Param name path string true "StatefulSet名称" @Success 200 {object} string @Router /k8s/cluster/{cluster}/statefulset/ns/{ns}/name/{name}/restart [post]
func (*Controller) Scale ¶ added in v0.0.145
func (cc *Controller) Scale(c *response.Context)
@Summary 扩缩容StatefulSet @Security BearerAuth @Param cluster query string true "集群名称" @Param ns path string true "命名空间" @Param name path string true "StatefulSet名称" @Param replica path int true "副本数" @Success 200 {object} string @Router /k8s/cluster/{cluster}/statefulset/ns/{ns}/name/{name}/scale/replica/{replica} [post]
func (*Controller) Undo ¶ added in v0.0.145
func (cc *Controller) Undo(c *response.Context)
@Summary 回滚StatefulSet到指定版本 @Security BearerAuth @Param cluster query string true "集群名称" @Param ns path string true "命名空间" @Param name path string true "StatefulSet名称" @Param revision path int true "版本号" @Success 200 {object} string @Router /k8s/cluster/{cluster}/statefulset/ns/{ns}/name/{name}/revision/{revision}/rollout/undo [post]