Skip to main content
This guide shows you how to create a cluster from registered machines.

Prerequisities

To follow this guide you must have machines registered to your Omni instance. Refer to the Register machines with Omni section to understand how to register your specific machine to Omni. You can create a cluster in Omni using this registered machines through the Omni UI, or using cluster templates through manual or dynamic machine allocation.
When creating a cluster using cluster templates with manually allocated machines, first identify the unique ID of each machine so the template can reference them.

Step 1: Get the machine UUID

For each machine you want to include in the cluster:
  1. Select the Machines tab.
  2. Click the button on the machine.
  3. Click Copy Machine ID.
Repeat this for each control plane and worker machine you plan to use.Copy Machine ID

Step 2: Create a cluster template file

A cluster template is made up of multiple documents separated by ---. Each document defines a different aspect of your cluster, the cluster itself, control plane nodes, worker nodes, and per-machine install settings.Create a file called cluster.yaml and populate it with the following, replacing each placeholder with your own values:
kind: Cluster
name: example
kubernetes:
  version: <kubernetes-version>
talos:
  version: <talos-version>
---
kind: ControlPlane
machines:
  - <control-plane-machine-uuid-1>
---
kind: Workers
machines:
  - <worker-machine-uuid>
---
kind: Machine
name: <control-plane-machine-uuid>
install:
  disk: /dev/<disk>
---
kind: Machine
name: <worker-machine-uuid>
install:
  disk: /dev/<disk>
  • <kubernetes-version>: The Kubernetes version for your cluster.
  • <talos-version>: The Talos Linux version for your cluster.
  • <control-plane-machine-uuid>: The UUID of the control plane machine.
  • <worker-machine-uuid>: The UUID of the worker machine.
  • <disk>: The name of the install disk on each machine (e.g. sda).

Step 3: (Optional) Enable additional features

To enable features such as disk encryption or workload proxying, add a features block to the Cluster document:
kind: Cluster
name: example
kubernetes:
  version: <kubernetes-version>
talos:
  version: <talos-version>
features:
  enableWorkloadProxy: true
  diskEncryption: true
You can also patch your cluster template to apply further configuration changes. See the cluster templates reference for the full list of available options.

Step 4: Validate the cluster template

omnictl cluster template validate -f cluster.yaml

Step 5: Create the cluster

omnictl cluster template sync -f cluster.yaml --verbose

Step 6: Wait for the cluster to be ready

omnictl cluster template status -f cluster.yaml