Skip to main content

ParseRestartPolicy

Gets k8s restart policy from flyte kubeflow plugins restart policy.

def ParseRestartPolicy(
flyteRestartPolicy: pluginsIdl.RestartPolicy
) - > kubeflowv1.RestartPolicy

Parses the Flyte Kubeflow plugins restart policy and converts it to a Kubernetes restart policy. This function is used to map restart policy enumerations between Flyte and Kubernetes.

Parameters

NameTypeDescription
flyteRestartPolicypluginsIdl.RestartPolicyThe restart policy defined by Flyte Kubeflow plugins, which needs to be converted to a Kubernetes-compatible format.

Returns

TypeDescription
kubeflowv1.RestartPolicyThe corresponding Kubernetes restart policy enumeration.