Reputation: 5527
Using AWS EC2 to install Rancher cluster. Then setup Kubernetes cluster from Rancher server.
About auto scaling, there are some ways to do:
https://rancher.com/docs/rancher/v1.6/en/cattle/webhook-service/
This way should use monitoring tool Prometheus to monitor CPU usage, then add or delete nodes due to alerting.
This can well done for Rancher cluster.
https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale-walkthrough/
It's official horizontal pod autoscaling way.
It's also a official auto scaling way for Kubernets cluster.
About this way, how to connect it to Rancher cluster and Kubernetes cluster running on EC2?
There are many ways to do the auto scaling, but which is the best way? And the very important thing is, how to use AWS Auto Scaling for this architecture?
Upvotes: 1
Views: 3500
Reputation: 97
Since you deployed Kubernetes with Rancher, you should use Rancher webhooks for this operation. Use Prometheus/Grafana to set up webhook when CPU utilization is over some %.
Upvotes: 1