allow setting Kubernetes tolerations in KFP pipelines #2823
Labels
component:pipeline-editor
pipeline editor
component:pipeline-runtime
issues related to pipeline runtimes e.g. kubeflow pipelines
kind:enhancement
New feature or request
Milestone
Related to #2681
Background
It is common practice in Kubernetes to apply a taint to Nodes with accelerator hardware (like GPUs), so that resources are not wasted by Pods which do not require the accelerator.
Currently, there is no way to specify a Pod toleration in Elyra Kubeflow pipelines, this means that running Elyra pipelines with GPUs is effectively impossible on a well-designed Kubernetes cluster.
Solution
We can resolve this by allowing users to specify a list of "tolerations" in a similar way to our "volume mounts" (see PR #2799).
We only need to allow the user to set
key
,operator
,value
, andeffect
, becausetolerationSeconds
is intended for cluster management, rather than scheduling.References:
kfp.dsl.BaseOp().add_toleration()
for more information about adding tolerations in KFPToleration v1 core
spec for details about how a toleration is defined.Examples
This toleration will match taints of key=
my-key
and value=my-value
with effect=NoSchedule
:This toleration will match taints of key=
my-key
and value=my-value
with ANY effect:This toleration will match taints of key=
my-key
and ANY value with ANY effect:The text was updated successfully, but these errors were encountered: