SupersetScalers

概述
SupersetScalers
是一个插件式方案的kubernetes
水平pod
autoscaler
控制器. 您可以使用HPAScaler
在 kubernetes 中定义的支持scale
资源(例如Deployment
和StatefulSet
以及ReplicaSet
)的任何种类的对象。
安装
- 安装CRD
kubectl apply -f config/crd/k8s.q1.com_hpascalers.yaml
- 安装
RBAC
# create ClusterRole
kubectl apply -f config/rbac/role.yaml
# create ServiceAccount
kubectl apply -f config/rbac/service_account.yaml
# create ClusterRolebinding
kubectl apply -f config/rbac/role_binding.yaml
- 部署
supersetscaler-controller
kubectl apply -f config/deploy/deploy.yaml
- 验证安装
kubectl get deploy supersetscaler-controller -n kube-system -o wide
➜ supersetscaler-controller git:(master) ✗ kubectl get deploy supersetscaler-controller -n kube-system
NAME DESIRED CURRENT UP-TO-DATE AVAILABLE AGE
supersetscaler-controller 1 1 1 1 49s
例子
请试用示例文件夹中的示例。
Plugin
- rabbitmq
- rocketmq
- kafka
- redis
- http
- shell
- python
- lua
Makefile help
Usage:
make <target>
General
help Display this help.
Development
manifests Generate ClusterRole and CustomResourceDefinition objects.
generate Generate code containing DeepCopy, DeepCopyInto, and DeepCopyObject method implementations.
fmt Run go fmt against code.
vet Run go vet against code.
test Run tests.
Build
build Build manager binary.
run Run a controller from your host.
docker-build Build docker image with the manager.
docker-push Push docker image with the manager.
Deployment
install Install CRDs into the K8s cluster specified in ~/.kube/config.
uninstall Uninstall CRDs from the K8s cluster specified in ~/.kube/config. Call with ignore-not-found=true to ignore resource not found errors during deletion.
deploy Deploy controller to the K8s cluster specified in ~/.kube/config.
undeploy Undeploy controller from the K8s cluster specified in ~/.kube/config. Call with ignore-not-found=true to ignore resource not found errors during deletion.
controller-gen Download controller-gen locally if necessary.
envtest Download envtest-setup locally if necessary.