Skip to content

Meta Labels

vzakaznikov edited this page Feb 28, 2024 · 13 revisions

Using Meta-Labels

Meta-labels can be used to define custom runner labels that will be replaced by other supported labels such as:

The meta-labels can be defined using the --meta-labels option. More than one meta-label can be defined.

For example,

github-hetzner-runners --meta-labels test-arm "self-hosted,type-cax21,image-arm-system-ubuntu-22.04" --meta-labels test-x86 "self-hosted,type-cpx21,image-x86-system-ubuntu-22.04"

will define the following two meta-labels:

  • test-arm* that will use the lables self-hosted,type-cax21,image-arm-system-ubuntu-22.04
  • test-x86* that will use the lables self-hosted,type-cpx21,image-x86-system-ubuntu-22.04

Once meta-labels are defined you can use them to request a runner with the corresponding labels.

job-name:
   runs-on: [test-arm]

that will be equivalent to

job-name:
   runs-on: [self-hosted, type-cax21, image-arm-system-ubuntu-22.04]

and

job-name:
   runs-on: [test-x86]

that will be equivalent to

job-name:
   runs-on: [self-hosted, type-cpx21, image-x86-system-ubuntu-22.04]
Clone this wiki locally