4.Replicaset和ReplicationController
kubectl create -f {rs yam fille | rc yam fille}
rs_nginx.yml
注意:新版本才支持Replicaset,相比ReplicationController,Replicaset支持new set-based selector
查看Replicaset:kubectl get rs
横向扩展pod数:kubectl scale rs {rs name} --replicas={pod 数}
查看ReplicationController:kubectl get rc
删除ReplicationController:kubectl delete -f {rc yaml file}
横向扩展pod数:kubectl scale rc {rc name} --replicas={pod 数}
Last updated
Was this helpful?