k8s metric-server实现弹性伸缩

cd /root/k8s_1.15_yaml/k8s_yaml/metrics
kubectl create -f .
yum install httpd-tools -y
vim /etc/hosts
10.0.0.12  nginx.weiyongdong.com
curl nginx.weiyongdong.com
#压测
kubectl autoscale deployment nginx --max=10 --min=1 --cpu-percent=5
ab -n 1000000 -c 100 http://nginx.weiyongdong.com/