在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称(OpenSource Name):kubernetes-sigs/kube-scheduler-simulator开源软件地址(OpenSource Url):https://github.com/kubernetes-sigs/kube-scheduler-simulator开源编程语言(OpenSource Language):Go 75.0%开源软件介绍(OpenSource Introduction):Kubernetes scheduler simulatorHello world. Here is Kubernetes scheduler simulator. Nowadays, the scheduler is configurable/extendable in the multiple ways:
But, unfortunately, not all configurations/expansions yield good results. Those who customize the scheduler need to make sure their scheduler is working as expected, and doesn't have an unacceptably negative impact on the scheduling. In real Kubernetes, we cannot know the results of scheduling in detail without reading the logs, which usually require privileged access to the control plane. That's way we are developing a simulator for kube-scheduler -- you can try out the behavior of the scheduler with web UI while checking which plugin made what decision for which Node. Simulator's architectureWe have several components:
SimulatorSimulator internally has kube-apiserver, scheduler, and HTTP server. You can create any resources by communicating with kube-apiserver via kubectl, k8s client library, or web UI. See the following docs to know more about simulator:
Web UIWeb UI is one of the clients of simulator, but it's optimized for simulator. From the web, you can create/edit/delete these resources to simulate a cluster.
You can create resources with yaml file as usual. And, after pods are scheduled, you can see the results of
You can configure the scheduler on the simulator through KubeSchedulerConfiguration. Scheduler Configuration | Kubernetes You can pass a KubeSchedulerConfiguration file via the environment variable Note: changes to any fields other than If you want to use your custom plugins as out-of-tree plugins in the simulator, please follow this doc. Getting startedRun simulator with DockerWe have docker-compose.yml to run the simulator easily. You can use the following command. # build the images for web frontend and simulator server, then start the containers.
make docker_build_and_up Then, you can access the simulator with http://localhost:3000 Note: Insufficient memory allocation may cause problems in building the image. Please allocate enough memory in that case. Run simulator locallyYou have to run frontend, server and etcd. Run simulator server and etcdTo run this simulator's server, you have to install Go and etcd. You can install etcd with kubernetes/kubernetes/hack/install-etcd.sh. cd simulator
make start It starts etcd and simulator-server locally. Run simulator frontendTo run the frontend, please see README.md on ./web dir. Contributingsee CONTRIBUTING.md Community, discussion, contribution, and supportLearn how to engage with the Kubernetes community on the community page. You can reach the maintainers of this project at: Code of conductParticipation in the Kubernetes community is governed by the Kubernetes Code of Conduct. |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论