Skip to main content

Specification

info

This feature is in beta. Please leave feedback via our community GitHub or Slack.

Overview

A Signadot Job Runner Group specification describes how jobs would likely will be running and the environment where will be executed.

name: my-jrg
spec:
cluster: your-cluster-name
labels:
my-custom-label: foo
env: bar
namespace: signadot
jobTimeout: 1h
image: ubuntu:latest
podTemplate:
spec:
containers:
- image: ubuntu:latest
name: main
resources: {}
scaling:
manual:
desiredPods: 1

This document details all the fields and constraints associated with a valid jobrunnergroup specification. A working example is available here.

Update constraints

A jobrunnergroup may be updated. Only some fields are mutable, the rest are immutable. In addition, some constraints apply.

name

The name is a string used to identify the job runner group. The name must be unique amongst all jobrunnergroups associated with the Signadot organization used to create the job runner group.

A name must

  • be no longer than 30 bytes in length.
  • contain only lowercase alphanumeric characters or '-'
  • start with an alphabetic character
  • end with an alphanumeric character

The name is required and immutable.

spec

The jobrunnergroup spec is required and contains all components of the specification except the name. Some parts of the spec are mutable and some are immutable.

spec.cluster

The cluster associated with a jobrunnergroup is a string which identifies a cluster registered with Signadot by name. In general, the cluster should have the Signadot Operator installed. The cluster name should not exceed 255 bytes in length.

cluster is required and immutable.

spec.namespace

The namespace in the cluster where pods run.

namespace is immutable.

If namespace is empty or not specified, the value signadot is used as a default.

spec.jobTimeout

Duration after which job execution times out. Neither queue time nor artifact upload time is taken into account.

The value should be an unsigned integer not exceeding 32 bits followed by a units character, which can be one of the following.

  • 'm' for minutes
  • 'h' for hours
  • 'd' for days
  • 'w' for weeks

Defaults to "30m".

spec.labels

Labels are a map from strings to strings, for example

spec:
labels:
dev: jane
feature: x

A label key must not exceed 255 bytes in length and must contain at least 1 character. Additionally, it must contain only the characters

A-Z // upercase alphabetic
a-z // lowercase alphabetic
0-9 // numeric
- // dash
_ // underscore

A label value can be an arbitrary string which also must not exceed 255 bytes in length and must contain at least one character. However, value contents are not otherwise restricted.

Jobrunnergroup labels are optional and mutable.

spec.image

Specify what image would be used internally as part of the runner. Can be a custom, one of the maintained by Signadot or any docker images.

spec.podTemplate

The podTemplate field provides an optional base pod template spec describing a base Pod specification for Pods on which jobs are run.

This spec is used as a basis on which a Pod is created for the JobRunnerGroup, by defining a shared volume, appending an init container, and defining the main container command to run a GRPC service for executing Jobs.

A podTemplate can be useful for specifying a service account, secret mounts, resource limits, and other runtime configuration.

A podTemplate must meet the following constraints:

  • If restartPolicy is specified, it must be "Never".
  • If an image or namespace is specified, it must not conflict with spec.image or spec.namespace.
  • If an init container is specified, it must not be named signadot-job-executor-init.
  • If a shared volume is specified, it must not be named signadot-job-executor.
  • Finally, the name must be not specified or empty; the name will be determined by the Signadot Operator.

spec.scaling

The scaling field is used to define the scaling of pods associated with the JobRunnerGroup.

The object associated with the scaling field contains 1 supported subfield, manual, which allows one to specify the desired number of pods dedicated to running jobs:

scaling:
manual:
desiredPods: 2

The sub-field auto is reserved for future use.