Developer automates full Kubernetes HA cluster setup on a single KVM host

A developer frustrated by repeatedly rebuilding a homelab Kubernetes cluster by hand created a shell script that automates the entire process with a single command. The script provisions six VMs on one KVM host, configures HAProxy as a load balancer, initializes a three-node control-plane cluster using kubeadm with stacked etcd, and adds two worker nodes with ingress-nginx. It uses Rocky Linux 9 cloud images with cloud-init to avoid manual OS installation, and runs node preparation steps in parallel to cut setup time to roughly 10–20 minutes. The script is divided into idempotent stages, so a failed run can be resumed from the point of failure rather than restarted from scratch. The project is aimed at homelab enthusiasts and those studying for the Certified Kubernetes Administrator exam, and has been published with a full README.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)
Log in to join the discussion and vote.
Log in