github.com/oam-dev/kubevela@v1.9.11/charts/vela-core/templates/defwithtemplate/suspend.yaml (about)

     1  # Code generated by KubeVela templates. DO NOT EDIT. Please edit the original cue file.
     2  # Definition source cue file: vela-templates/definitions/internal/suspend.cue
     3  apiVersion: core.oam.dev/v1beta1
     4  kind: WorkflowStepDefinition
     5  metadata:
     6    annotations:
     7      custom.definition.oam.dev/category: Process Control
     8      definition.oam.dev/description: Suspend the current workflow, it can be resumed by 'vela workflow resume' command.
     9    name: suspend
    10    namespace: {{ include "systemDefinitionNamespace" . }}
    11  spec:
    12    schematic:
    13      cue:
    14        template: |
    15          import (
    16          	"vela/op"
    17          )
    18  
    19          suspend: op.#Suspend & {
    20          	if parameter.duration != _|_ {
    21          		duration: parameter.duration
    22          	}
    23          	if parameter.message != _|_ {
    24          		message: parameter.message
    25          	}
    26          }
    27  
    28          parameter: {
    29          	// +usage=Specify the wait duration time to resume workflow such as "30s", "1min" or "2m15s"
    30          	duration?: string
    31          	// +usage=The suspend message to show
    32          	message?: string
    33          }
    34