Skip to main content

Runtime Pools

Runtime Pool Specification

Runtime Pools maintain a pool of Runtimes ready to be assigned to users. The size is configurable per pool.

When assigned to a user, Runtimes are injected with the User Secrets.

Your cluster needs to be provisioned to support the size of the defined pools.

The complete specification is available here and the following sections show simple examples.

Manage the Runtime Pools

kubectl get runtime-pools.datalayer.io -A
kubectl get runtime-pools.datalayer.io -o yaml -A

Relation with Runtime Environments

If a Runtime Pool defines some resources, they override the defaults set in Runtime Environments.

Runtime Pool Example

cat <<EOF | kubectl apply -f -
apiVersion: datalayer.io/v1
kind: RuntimePool
metadata:
name: python-simple-pool
namespace: datalayer-runtimes
labels:
project.datalayer.io/name: dev
spec:
environment: python-simple-env
size: 3
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: role.datalayer.io/runtime
operator: In
values:
- "true"
- key: node.datalayer.io/variant
operator: In
values:
- medium
- key: node.datalayer.io/xpu
operator: In
values:
- cpu
burningRate: 0.01
cull:
seconds: 999999
EOF