A flexible and scalable platform for running Kubernetes control plane APIs.
- Provide lightweight Kube API Server instances and selected controllers as a service.
- Provide a flexible architecture for the storage backend, e.g.:
- shared DB for API servers,
- dedicated DB for each API server,
- etcd DB or Kine + Postgres DB
- Flexibility in choice of API Server build:
- upstream Kube (e.g.
registry.k8s.io/kube-apiserver:v1.27.1
), - trimmed down API Server builds (e.g. multicluster control plane)
- upstream Kube (e.g.
- Single binary CLI for improved user experience:
- initialize, install operator, manage lifecycle of control planes and contexts.
kind and kubectl are required. A kind hosting cluster is created automatically by the kubeflex CLI. You may also install KubeFlex on other Kube distros, as long as they support an nginx ingress with SSL passthru, or on OpenShift. See the User's Guide for more details.
Download the latest kubeflex CLI binary release for your OS/Architecture from the
release page and copy it
to /usr/local/bin
using the following command:
sudo su <<EOF
bash <(curl -s https://raw.githubusercontent.com/kubestellar/kubeflex/main/scripts/install-kubeflex.sh) --ensure-folder /usr/local/bin --strip-bin
EOF
If you have Homebrew, use the following commands to install kubeflex:
brew tap kubestellar/kubeflex https://github.com/kubestellar/kubeflex
brew install kubeflex
To upgrade the kubeflex CLI to the latest release, you may run:
brew upgrade kubeflex
Create the hosting kind cluster with ingress controller and install the kubeflex operator:
kflex init --create-kind
Create a control plane:
kflex create cp1
Interact with the new control plane, for example get namespaces and create a new one:
kubectl get ns
kubectl create ns myns
Create a second control plane and check that the namespace created in the first control plane is not present:
kflex create cp2
kubectl get ns
To go back to the hosting cluster context, use the ctx
command:
kflex ctx
To switch back to a control plane context, use the
ctx <control plane name>
command, e.g:
kflex ctx cp1
To delete a control plane, use the delete <control plane name>
command, e.g:
kflex delete cp1
Read the User's Guide to learn more about using KubeFlex for your project and how to create and interact with different types of control planes, such as vcluster and Open Cluster Management.