Running kwok out of cluster
#
This document walks you through how to run kwok out of cluster for a Kubernetes cluster.Prerequisites #
Firstly, you need to have a Kubernetes cluster, and the kwok command-line tool must be available in your PATH.
Install kwok
#
Install kwok in your environment.
Running #
Next, you can run kwok out of cluster by using the --kubeconfig flag.
The default simulation behavior is defined in
fast stage for pod and
fast stage for node.
They are suitable for scenarios such as scheduling and autoscaling.
You can customize the simulation behavior with --config flag to point to your own configuration file.
kwok \
--kubeconfig=~/.kube/config \
--manage-all-nodes=false \
--manage-nodes-with-annotation-selector=kwok.x-k8s.io/node=fake \
--manage-nodes-with-label-selector= \
--manage-single-node= \
--cidr=10.0.0.1/24 \
--node-ip=10.0.0.1 \
--node-lease-duration-seconds=40
Finally, you can see the kwok is running out of cluster for the Kubernetes cluster.
Next steps #
Now, you can use kwok to
manage nodes and pods in the Kubernetes cluster.