GNU/Linux ◆ xterm-256color ◆ bash 357 views

This is a quick demo of how we can manage Libvirt Virtual Machines (VM) with Metal3.io. We are using scripts from https://github.com/metal3-io/metal3-dev-env, which is meant for testing and developing code for Metal3.io. Steps we took:

  1. $ git clone https://github.com/metal3-io/metal3-dev-env
  2. $ cd metal3-dev-env
  3. $ make and wait until the run is completed. This will create a Kubernetes cluster, install Metal3 and CAPI controllers, create Libvirt VMs, apply Custom Resources, and setup the necessary networking. By the end of this run, you will have Metal3 controller up and running and two Machines ready to be provisioned.

Next step is to provision them, and for that we use ready made scripts as follows:

  1. $ cd metal3-dev-env/scripts/provision
  2. $ ./cluster.sh ## to provision a cluster
  3. $ ./controlplane.sh ## to provision a Kubernetes controlplane node
  4. $ ./worker.sh ## to provision a Kubernetes worker node It will take ~15 mins for those two nodes to get provisioned and join the Kubernetes cluster, and by the end of it you should have your target cluster up running on top of Libvirt VMs.