Create a Machine Class

A guide on how to create a machine class.

This guide shows you how to create and a machine class.

First, click the “Machine Classes” section button in the sidebar.

<figcaption class="card-body px-0 pt-2 pb-0">
	<p class="card-text">

Next, click the “Create Machine Class” button.

<figcaption class="card-body px-0 pt-2 pb-0">
	<p class="card-text">

Add machine query conditions by typing them manually in the input box.

<figcaption class="card-body px-0 pt-2 pb-0">
	<p class="card-text">

Clicking the label in the machine list will add them to the input box.

<figcaption class="card-body px-0 pt-2 pb-0">
	<p class="card-text">

Clicking on “+” will add blocks to match the machines using boolean OR operator.

<figcaption class="card-body px-0 pt-2 pb-0">
	<p class="card-text">

<figcaption class="card-body px-0 pt-2 pb-0">
	<p class="card-text">

Name the machine class.

<figcaption class="card-body px-0 pt-2 pb-0">
	<p class="card-text">

Click “Create Machine Class”.

<figcaption class="card-body px-0 pt-2 pb-0">
	<p class="card-text">

Create a file called machine-class.yaml with the following content:

metadata:
  namespace: default
  type: MachineClasses.omni.sidero.dev
  id: test
spec:
  matchlabels:
    # matches machines with amd64 architecture and more than 2 CPUs
    - omni.sidero.dev/arch: amd64, omni.sidero.dev/cpus > 2

Create the machine class:

omnictl apply -f machine-class.yaml