diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index a915ff1df..273ee1b6b 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml @@ -109,3 +109,12 @@ jobs: GO111MODULE: "on" with: args: make install && make lint + + crd-check: + name: Check CRD code is up to date + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Check CRD code + run: DELTA_CHECK=true make op_code_generate \ No newline at end of file diff --git a/.gitignore b/.gitignore index 426b90e2d..5bc9551bc 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,4 @@ bin .DS_Store _test boilerplate/lyft/end2end/tmp +github.com \ No newline at end of file diff --git a/Makefile b/Makefile index 84938afdd..d21909c7a 100644 --- a/Makefile +++ b/Makefile @@ -3,6 +3,24 @@ include boilerplate/flyte/docker_build/Makefile include boilerplate/flyte/golang_test_targets/Makefile include boilerplate/flyte/end2end/Makefile +CRD_OPTIONS ?= "crd:generateEmbeddedObjectMeta=true" +CONTROLLER_GEN = $(shell pwd)/bin/controller-gen +OPENAPI_GEN = $(shell pwd)/bin/openapi-gen +CRD_FILE = $(shell pwd)/manifests/base/crds/flyteworkflow.flyte.net_flyteworkflows.yaml + +controller-gen: ## Download controller-gen locally if necessary. + $(call go-get-tool,$(CONTROLLER_GEN),sigs.k8s.io/controller-tools/cmd/controller-gen@v0.7.0) + +openapi-gen: + $(call go-get-tool,$(OPENAPI_GEN),k8s.io/kube-openapi/cmd/openapi-gen@v0.0.0-20200805222855-6aeccd4b50c6) + +manifests: controller-gen ## Generate CustomResourceDefinition objects. + $(CONTROLLER_GEN) $(CRD_OPTIONS) paths="./pkg/apis/flyteworkflow/..." output:crd:artifacts:config=manifests/base/crds || true + # Kubernetes cannot allow additionalProperties value to be empty. + # More detail: https://github.com/kubernetes/kubernetes/issues/90504 + perl -p -i -e 's/additionalProperties: {}/additionalProperties: true/g' $(CRD_FILE) + perl -p -i -e 's/flyteworkflows.flyteworkflow.flyte.net/flyteworkflows.flyte.lyft.com/g' $(CRD_FILE) + perl -p -i -e 's/flyteworkflow.flyte.net/flyte.lyft.com/g' $(CRD_FILE) .PHONY: update_boilerplate update_boilerplate: @@ -26,7 +44,12 @@ cross_compile: GOOS=linux GOARCH=amd64 go build -o bin/cross/flytepropeller ./cmd/controller/main.go GOOS=linux GOARCH=amd64 go build -o bin/cross/kubectl-flyte ./cmd/kubectl-flyte/main.go -op_code_generate: +openapi_generate: openapi-gen + $(OPENAPI_GEN) -i github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1 \ + -p github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1 \ + --go-header-file hack/boilerplate.go.txt 2>&1 > /dev/null + +op_code_generate: openapi_generate manifests @RESOURCE_NAME=flyteworkflow OPERATOR_PKG=github.com/flyteorg/flytepropeller ./hack/update-codegen.sh benchmark: @@ -49,3 +72,17 @@ golden: .PHONY: generate generate: download_tooling @go generate ./... + +# go-get-tool will 'go get' any package $2 and install it to $1. +PROJECT_DIR := $(shell dirname $(abspath $(firstword $(MAKEFILE_LIST)))) +define go-get-tool +@[ -f $(1) ] || { \ +set -e ;\ +TMP_DIR=$$(mktemp -d) ;\ +cd $$TMP_DIR ;\ +go mod init tmp ;\ +echo "Downloading $(2)" ;\ +GOBIN=$(PROJECT_DIR)/bin go get $(2) ;\ +rm -rf $$TMP_DIR ;\ +} +endef diff --git a/go.mod b/go.mod index 53dc37d45..7ad053399 100644 --- a/go.mod +++ b/go.mod @@ -10,6 +10,7 @@ require ( github.com/flyteorg/flyteplugins v0.7.1 github.com/flyteorg/flytestdlib v0.4.0 github.com/ghodss/yaml v1.0.0 + github.com/go-openapi/spec v0.20.3 github.com/go-redis/redis v6.15.7+incompatible github.com/go-test/deep v1.0.7 github.com/golang/protobuf v1.4.3 @@ -29,6 +30,7 @@ require ( k8s.io/apimachinery v0.20.2 k8s.io/client-go v0.20.2 k8s.io/klog v1.0.0 + k8s.io/kube-openapi v0.0.0-20201113171705-d219536bb9fd sigs.k8s.io/controller-runtime v0.8.2 ) diff --git a/hack/update-codegen.sh b/hack/update-codegen.sh index 82a1ef21f..e92565f82 100755 --- a/hack/update-codegen.sh +++ b/hack/update-codegen.sh @@ -19,6 +19,7 @@ set -o errexit set -o nounset set -o pipefail +set +u : "${RESOURCE_NAME:?should be set for CRD}" : "${OPERATOR_PKG:?should be set for operator}" @@ -28,16 +29,34 @@ echo "Generating CRD: ${RESOURCE_NAME}, in package ${OPERATOR_PKG}..." SCRIPT_ROOT=$(dirname ${BASH_SOURCE})/.. CODEGEN_PKG=${CODEGEN_PKG:-$(cd ${SCRIPT_ROOT}; ls -d -1 ./vendor/k8s.io/code-generator 2>/dev/null || echo ../code-generator)} -# generate the code with: -# --output-base because this script should also be able to run inside the vendor dir of -# k8s.io/kubernetes. The output-base is needed for the generators to output into the vendor dir -# instead of the $GOPATH directly. For normal projects this can be dropped. -bash ${CODEGEN_PKG}/generate-groups.sh "deepcopy,client,informer,lister" \ - ${OPERATOR_PKG}/pkg/client \ - ${OPERATOR_PKG}/pkg/apis \ - ${RESOURCE_NAME}:v1alpha1 \ - --output-base "$(dirname ${BASH_SOURCE})/../../../.." \ - --go-header-file ${SCRIPT_ROOT}/hack/boilerplate.go.txt +if [[ -d ${CODEGEN_PKG} ]]; then + # generate the code with: + # --output-base because this script should also be able to run inside the vendor dir of + # k8s.io/kubernetes. The output-base is needed for the generators to output into the vendor dir + # instead of the $GOPATH directly. For normal projects this can be dropped. + bash ${CODEGEN_PKG}/generate-groups.sh "deepcopy,client,informer,lister" \ + ${OPERATOR_PKG}/pkg/client \ + ${OPERATOR_PKG}/pkg/apis \ + ${RESOURCE_NAME}:v1alpha1 \ + --output-base "$(dirname ${BASH_SOURCE})/../../../.." \ + --go-header-file ${SCRIPT_ROOT}/hack/boilerplate.go.txt +fi # To use your own boilerplate text use: # --go-header-file ${SCRIPT_ROOT}/hack/custom-boilerplate.go.txt + +# This section is used by GitHub workflow to ensure that the generation step was run +if [[ "$DELTA_CHECK" == true ]]; then + DIRTY=$(git status --porcelain) + if [ -n "$DIRTY" ]; then + echo "FAILED: CRD code updated without committing generated code." + echo "Ensure make op_code_generate has run and all changes are committed." + DIFF=$(git diff) + echo "diff detected: $DIFF" + DIFF=$(git diff --name-only) + echo "files different: $DIFF" + exit 1 + else + echo "SUCCESS: Generated CRD code is up to date." + fi +fi diff --git a/manifests/base/crds/flyteworkflow.flyte.net_flyteworkflows.yaml b/manifests/base/crds/flyteworkflow.flyte.net_flyteworkflows.yaml new file mode 100644 index 000000000..a4c44f4e3 --- /dev/null +++ b/manifests/base/crds/flyteworkflow.flyte.net_flyteworkflows.yaml @@ -0,0 +1,5196 @@ + +--- +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + annotations: + controller-gen.kubebuilder.io/version: v0.7.0 + creationTimestamp: null + name: flyteworkflows.flyte.lyft.com +spec: + group: flyte.lyft.com + names: + kind: FlyteWorkflow + listKind: FlyteWorkflowList + plural: flyteworkflows + shortNames: + - fly + singular: flyteworkflow + scope: Namespaced + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + description: 'FlyteWorkflow: represents one Execution Workflow object' + properties: + acceptedAt: + description: Specifies the time when the workflow has been accepted into + the system. + format: date-time + type: string + activeDeadlineSeconds: + description: StartTime before the system will actively try to mark it + failed and kill associated containers. Value must be a positive integer. + format: int64 + type: integer + apiVersion: + description: 'APIVersion defines the versioned schema of this representation + of an object. Servers should convert recognized schemas to the latest + internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + type: string + executionConfig: + description: Workflow-execution specifications and overrides + properties: + MaxParallelism: + description: Can be used to control the number of parallel nodes to + run within the workflow. This is useful to achieve fairness. + format: int32 + type: integer + RecoveryExecution: + description: Defines execution behavior for processing nodes. + properties: + domain: + description: Name of the domain the resource belongs to. A domain + can be considered as a subset within a specific project. + type: string + name: + description: User or system provided value for the resource. + type: string + project: + description: Name of the project the resource belongs to. + type: string + type: object + TaskPluginImpls: + additionalProperties: + properties: + MissingPluginBehavior: + format: int32 + type: integer + PluginsIDs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - MissingPluginBehavior + type: object + description: Maps individual task types to their alternate (non-default) + plugin handlers by name. + type: object + TaskResources: + description: Defines the resource requests and limits specified for + tasks run as part of this execution that ought to be applied at + execution time. + properties: + Limits: + description: A hard limit, a task cannot consume resources greater + than the limit specifies. + properties: + CPU: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + EphemeralStorage: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + GPU: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + Memory: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + Storage: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + required: + - CPU + - EphemeralStorage + - GPU + - Memory + - Storage + type: object + Requests: + description: If the node where a task is running has enough of + a resource available, a container may use more resources than + its request for that resource specifies. + properties: + CPU: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + EphemeralStorage: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + GPU: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + Memory: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + Storage: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + required: + - CPU + - EphemeralStorage + - GPU + - Memory + - Storage + type: object + required: + - Limits + - Requests + type: object + required: + - MaxParallelism + - RecoveryExecution + - TaskPluginImpls + - TaskResources + type: object + executionId: + properties: + domain: + description: Name of the domain the resource belongs to. A domain + can be considered as a subset within a specific project. + type: string + name: + description: User or system provided value for the resource. + type: string + project: + description: Name of the project the resource belongs to. + type: string + type: object + inputs: + type: object + kind: + description: 'Kind is a string value representing the REST resource this + object represents. Servers may infer this from the endpoint the client + submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + type: string + metadata: + type: object + node-defaults: + description: Defaults value of parameters to be used for nodes if not + set by the node. + properties: + interruptible: + description: Default behaviour for Interruptible for nodes unless + explicitly set at the node level. + type: boolean + type: object + rawOutputDataConfig: + description: RawOutputDataConfig defines the configurations to use for + generating raw outputs (e.g. blobs, schemas). + properties: + output_location_prefix: + description: Prefix for where offloaded data from user workflows will + be written e.g. s3://bucket/key or s3://bucket/ + type: string + type: object + securityContext: + description: Security context fields to define privilege and access control + settings + properties: + run_as: + description: run_as encapsulates the identity a pod should run as. + If the task fills in multiple fields here, it'll be up to the backend + plugin to choose the appropriate identity for the execution engine + the task will run on. + properties: + iam_role: + description: iam_role references the fully qualified name of Identity + & Access Management role to impersonate. + type: string + k8s_service_account: + description: k8s_service_account references a kubernetes service + account to impersonate. + type: string + oauth2_client: + description: oauth2_client references an oauth2 client. Backend + plugins can use this information to impersonate the client when + making external calls. + properties: + client_id: + description: client_id is the public id for the client to + use. The system will not perform any pre-auth validation + that the secret requested matches the client_id indicated + here. + type: string + client_secret: + description: client_secret is a reference to the secret used + to authenticate the OAuth2 client. + properties: + group: + description: The name of the secret group where to find + the key referenced below. For K8s secrets, this should + be the name of the v1/secret object. For Confidant, + this should be the Credential name. For Vault, this + should be the secret name. For AWS Secret Manager, this + should be the name of the secret. + type: string + group_version: + description: The group version to fetch. This is not supported + in all secret management systems. It'll be ignored for + the ones that do not support it. + type: string + key: + description: The name of the secret to mount. This has + to match an existing secret in the system. It's up to + the implementation of the secret management system to + require case sensitivity. For K8s secrets, Confidant + and Vault, this should match one of the keys inside + the secret. For AWS Secret Manager, it's ignored. + type: string + mount_requirement: + description: mount_requirement is optional. Indicates + where the secret has to be mounted. If provided, the + execution will fail if the underlying key management + system cannot satisfy that requirement. If not provided, + the default location will depend on the key management + system. + format: int32 + type: integer + type: object + type: object + type: object + secrets: + description: secrets indicate the list of secrets the task needs in + order to proceed. Secrets will be mounted/passed to the pod as it + starts. If the plugin responsible for kicking of the task will not + run it on a flyte cluster (e.g. AWS Batch), it's the responsibility + of the plugin to fetch the secret (which means propeller identity + will need access to the secret) and to pass it to the remote execution + engine. + items: + description: Secret encapsulates information about the secret a + task needs to proceed. An environment variable FLYTE_SECRETS_ENV_PREFIX + will be passed to indicate the prefix of the environment variables + that will be present if secrets are passed through environment + variables. FLYTE_SECRETS_DEFAULT_DIR will be passed to indicate + the prefix of the path where secrets will be mounted if secrets + are passed through file mounts. + properties: + group: + description: The name of the secret group where to find the + key referenced below. For K8s secrets, this should be the + name of the v1/secret object. For Confidant, this should be + the Credential name. For Vault, this should be the secret + name. For AWS Secret Manager, this should be the name of the + secret. + type: string + group_version: + description: The group version to fetch. This is not supported + in all secret management systems. It'll be ignored for the + ones that do not support it. + type: string + key: + description: The name of the secret to mount. This has to match + an existing secret in the system. It's up to the implementation + of the secret management system to require case sensitivity. + For K8s secrets, Confidant and Vault, this should match one + of the keys inside the secret. For AWS Secret Manager, it's + ignored. + type: string + mount_requirement: + description: mount_requirement is optional. Indicates where + the secret has to be mounted. If provided, the execution will + fail if the underlying key management system cannot satisfy + that requirement. If not provided, the default location will + depend on the key management system. + format: int32 + type: integer + type: object + type: array + tokens: + description: tokens indicate the list of token requests the task needs + in order to proceed. Tokens will be mounted/passed to the pod as + it starts. If the plugin responsible for kicking of the task will + not run it on a flyte cluster (e.g. AWS Batch), it's the responsibility + of the plugin to fetch the secret (which means propeller identity + will need access to the secret) and to pass it to the remote execution + engine. + items: + description: OAuth2TokenRequest encapsulates information needed + to request an OAuth2 token. FLYTE_TOKENS_ENV_PREFIX will be passed + to indicate the prefix of the environment variables that will + be present if tokens are passed through environment variables. + FLYTE_TOKENS_PATH_PREFIX will be passed to indicate the prefix + of the path where secrets will be mounted if tokens are passed + through file mounts. + properties: + client: + description: client references the client_id/secret to use to + request the OAuth2 token. + properties: + client_id: + description: client_id is the public id for the client to + use. The system will not perform any pre-auth validation + that the secret requested matches the client_id indicated + here. + type: string + client_secret: + description: client_secret is a reference to the secret + used to authenticate the OAuth2 client. + properties: + group: + description: The name of the secret group where to find + the key referenced below. For K8s secrets, this should + be the name of the v1/secret object. For Confidant, + this should be the Credential name. For Vault, this + should be the secret name. For AWS Secret Manager, + this should be the name of the secret. + type: string + group_version: + description: The group version to fetch. This is not + supported in all secret management systems. It'll + be ignored for the ones that do not support it. + type: string + key: + description: The name of the secret to mount. This has + to match an existing secret in the system. It's up + to the implementation of the secret management system + to require case sensitivity. For K8s secrets, Confidant + and Vault, this should match one of the keys inside + the secret. For AWS Secret Manager, it's ignored. + type: string + mount_requirement: + description: mount_requirement is optional. Indicates + where the secret has to be mounted. If provided, the + execution will fail if the underlying key management + system cannot satisfy that requirement. If not provided, + the default location will depend on the key management + system. + format: int32 + type: integer + type: object + type: object + idp_discovery_endpoint: + description: idp_discovery_endpoint references the discovery + endpoint used to retrieve token endpoint and other related + information. + type: string + name: + description: name indicates a unique id for the token request + within this task token requests. It'll be used as a suffix + for environment variables and as a filename for mounting tokens + as files. + type: string + token_endpoint: + description: token_endpoint references the token issuance endpoint. + If idp_discovery_endpoint is not provided, this parameter + is mandatory. + type: string + type: + description: type indicates the type of the request to make. + Defaults to CLIENT_CREDENTIALS. + format: int32 + type: integer + type: object + type: array + type: object + serviceAccountName: + description: '[DEPRECATED] ServiceAccountName is the name of the ServiceAccount + to use to run this pod. [DEPRECATED] More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ + [DEPRECATED] +optional' + type: string + spec: + description: WorkflowSpec is the spec for the actual Flyte Workflow (DAG) + properties: + connections: + description: 'Defines the set of connections (both data dependencies + and execution dependencies) that the graph is formed of. The execution + engine will respect and follow these connections as it determines + which nodes can and should be executed. Deprecated: Please use Connections' + properties: + DownstreamEdges: + additionalProperties: + items: + type: string + type: array + type: object + UpstreamEdges: + additionalProperties: + items: + type: string + type: array + type: object + type: object + edges: + description: Defines the set of connections (both data dependencies + and execution dependencies) that the graph is formed of. The execution + engine will respect and follow these connections as it determines + which nodes can and should be executed. + properties: + downstream: + additionalProperties: + items: + type: string + type: array + type: object + upstream: + additionalProperties: + items: + type: string + type: array + type: object + required: + - downstream + - upstream + type: object + id: + type: string + nodes: + additionalProperties: + properties: + activeDeadline: + description: StartTime before the system will actively try to + mark it failed and kill associated containers. Value must + be a positive integer. This includes time spent waiting in + the queue. + type: string + affinity: + description: If specified, the pod's scheduling constraints + properties: + nodeAffinity: + description: Describes node affinity scheduling rules for + the pod. + properties: + preferredDuringSchedulingIgnoredDuringExecution: + description: The scheduler will prefer to schedule pods + to nodes that satisfy the affinity expressions specified + by this field, but it may choose a node that violates + one or more of the expressions. The node that is most + preferred is the one with the greatest sum of weights, + i.e. for each node that meets all of the scheduling + requirements (resource request, requiredDuringScheduling + affinity expressions, etc.), compute a sum by iterating + through the elements of this field and adding "weight" + to the sum if the node matches the corresponding matchExpressions; + the node(s) with the highest sum are the most preferred. + items: + description: An empty preferred scheduling term matches + all objects with implicit weight 0 (i.e. it's a + no-op). A null preferred scheduling term matches + no objects (i.e. is also a no-op). + properties: + preference: + description: A node selector term, associated + with the corresponding weight. + properties: + matchExpressions: + description: A list of node selector requirements + by node's labels. + items: + description: A node selector requirement + is a selector that contains values, a + key, and an operator that relates the + key and values. + properties: + key: + description: The label key that the + selector applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, the + values array must be non-empty. If + the operator is Exists or DoesNotExist, + the values array must be empty. If + the operator is Gt or Lt, the values + array must have a single element, + which will be interpreted as an integer. + This array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchFields: + description: A list of node selector requirements + by node's fields. + items: + description: A node selector requirement + is a selector that contains values, a + key, and an operator that relates the + key and values. + properties: + key: + description: The label key that the + selector applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, the + values array must be non-empty. If + the operator is Exists or DoesNotExist, + the values array must be empty. If + the operator is Gt or Lt, the values + array must have a single element, + which will be interpreted as an integer. + This array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + type: object + weight: + description: Weight associated with matching the + corresponding nodeSelectorTerm, in the range + 1-100. + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + requiredDuringSchedulingIgnoredDuringExecution: + description: If the affinity requirements specified + by this field are not met at scheduling time, the + pod will not be scheduled onto the node. If the affinity + requirements specified by this field cease to be met + at some point during pod execution (e.g. due to an + update), the system may or may not try to eventually + evict the pod from its node. + properties: + nodeSelectorTerms: + description: Required. A list of node selector terms. + The terms are ORed. + items: + description: A null or empty node selector term + matches no objects. The requirements of them + are ANDed. The TopologySelectorTerm type implements + a subset of the NodeSelectorTerm. + properties: + matchExpressions: + description: A list of node selector requirements + by node's labels. + items: + description: A node selector requirement + is a selector that contains values, a + key, and an operator that relates the + key and values. + properties: + key: + description: The label key that the + selector applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, the + values array must be non-empty. If + the operator is Exists or DoesNotExist, + the values array must be empty. If + the operator is Gt or Lt, the values + array must have a single element, + which will be interpreted as an integer. + This array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchFields: + description: A list of node selector requirements + by node's fields. + items: + description: A node selector requirement + is a selector that contains values, a + key, and an operator that relates the + key and values. + properties: + key: + description: The label key that the + selector applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, the + values array must be non-empty. If + the operator is Exists or DoesNotExist, + the values array must be empty. If + the operator is Gt or Lt, the values + array must have a single element, + which will be interpreted as an integer. + This array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + type: object + type: array + required: + - nodeSelectorTerms + type: object + type: object + podAffinity: + description: Describes pod affinity scheduling rules (e.g. + co-locate this pod in the same node, zone, etc. as some + other pod(s)). + properties: + preferredDuringSchedulingIgnoredDuringExecution: + description: The scheduler will prefer to schedule pods + to nodes that satisfy the affinity expressions specified + by this field, but it may choose a node that violates + one or more of the expressions. The node that is most + preferred is the one with the greatest sum of weights, + i.e. for each node that meets all of the scheduling + requirements (resource request, requiredDuringScheduling + affinity expressions, etc.), compute a sum by iterating + through the elements of this field and adding "weight" + to the sum if the node has pods which matches the + corresponding podAffinityTerm; the node(s) with the + highest sum are the most preferred. + items: + description: The weights of all of the matched WeightedPodAffinityTerm + fields are added per-node to find the most preferred + node(s) + properties: + podAffinityTerm: + description: Required. A pod affinity term, associated + with the corresponding weight. + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list + of label selector requirements. The + requirements are ANDed. + items: + description: A label selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: key is the label key + that the selector applies to. + type: string + operator: + description: operator represents + a key's relationship to a set + of values. Valid operators are + In, NotIn, Exists and DoesNotExist. + type: string + values: + description: values is an array + of string values. If the operator + is In or NotIn, the values array + must be non-empty. If the operator + is Exists or DoesNotExist, the + values array must be empty. This + array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator + is "In", and the values array contains + only "value". The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located + (affinity) or not co-located (anti-affinity) + with the pods matching the labelSelector + in the specified namespaces, where co-located + is defined as running on a node whose value + of the label with key topologyKey matches + that of any node on which any of the selected + pods is running. Empty topologyKey is not + allowed. + type: string + required: + - topologyKey + type: object + weight: + description: weight associated with matching the + corresponding podAffinityTerm, in the range + 1-100. + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + requiredDuringSchedulingIgnoredDuringExecution: + description: If the affinity requirements specified + by this field are not met at scheduling time, the + pod will not be scheduled onto the node. If the affinity + requirements specified by this field cease to be met + at some point during pod execution (e.g. due to a + pod label update), the system may or may not try to + eventually evict the pod from its node. When there + are multiple elements, the lists of nodes corresponding + to each podAffinityTerm are intersected, i.e. all + terms must be satisfied. + items: + description: Defines a set of pods (namely those matching + the labelSelector relative to the given namespace(s)) + that this pod should be co-located (affinity) or + not co-located (anti-affinity) with, where co-located + is defined as running on a node whose value of the + label with key matches that of any + node on which a pod of the set of pods is running + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list of + label selector requirements. The requirements + are ANDed. + items: + description: A label selector requirement + is a selector that contains values, a + key, and an operator that relates the + key and values. + properties: + key: + description: key is the label key that + the selector applies to. + type: string + operator: + description: operator represents a key's + relationship to a set of values. Valid + operators are In, NotIn, Exists and + DoesNotExist. + type: string + values: + description: values is an array of string + values. If the operator is In or NotIn, + the values array must be non-empty. + If the operator is Exists or DoesNotExist, + the values array must be empty. This + array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator is + "In", and the values array contains only + "value". The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located (affinity) + or not co-located (anti-affinity) with the pods + matching the labelSelector in the specified + namespaces, where co-located is defined as running + on a node whose value of the label with key + topologyKey matches that of any node on which + any of the selected pods is running. Empty topologyKey + is not allowed. + type: string + required: + - topologyKey + type: object + type: array + type: object + podAntiAffinity: + description: Describes pod anti-affinity scheduling rules + (e.g. avoid putting this pod in the same node, zone, etc. + as some other pod(s)). + properties: + preferredDuringSchedulingIgnoredDuringExecution: + description: The scheduler will prefer to schedule pods + to nodes that satisfy the anti-affinity expressions + specified by this field, but it may choose a node + that violates one or more of the expressions. The + node that is most preferred is the one with the greatest + sum of weights, i.e. for each node that meets all + of the scheduling requirements (resource request, + requiredDuringScheduling anti-affinity expressions, + etc.), compute a sum by iterating through the elements + of this field and adding "weight" to the sum if the + node has pods which matches the corresponding podAffinityTerm; + the node(s) with the highest sum are the most preferred. + items: + description: The weights of all of the matched WeightedPodAffinityTerm + fields are added per-node to find the most preferred + node(s) + properties: + podAffinityTerm: + description: Required. A pod affinity term, associated + with the corresponding weight. + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list + of label selector requirements. The + requirements are ANDed. + items: + description: A label selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: key is the label key + that the selector applies to. + type: string + operator: + description: operator represents + a key's relationship to a set + of values. Valid operators are + In, NotIn, Exists and DoesNotExist. + type: string + values: + description: values is an array + of string values. If the operator + is In or NotIn, the values array + must be non-empty. If the operator + is Exists or DoesNotExist, the + values array must be empty. This + array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator + is "In", and the values array contains + only "value". The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located + (affinity) or not co-located (anti-affinity) + with the pods matching the labelSelector + in the specified namespaces, where co-located + is defined as running on a node whose value + of the label with key topologyKey matches + that of any node on which any of the selected + pods is running. Empty topologyKey is not + allowed. + type: string + required: + - topologyKey + type: object + weight: + description: weight associated with matching the + corresponding podAffinityTerm, in the range + 1-100. + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + requiredDuringSchedulingIgnoredDuringExecution: + description: If the anti-affinity requirements specified + by this field are not met at scheduling time, the + pod will not be scheduled onto the node. If the anti-affinity + requirements specified by this field cease to be met + at some point during pod execution (e.g. due to a + pod label update), the system may or may not try to + eventually evict the pod from its node. When there + are multiple elements, the lists of nodes corresponding + to each podAffinityTerm are intersected, i.e. all + terms must be satisfied. + items: + description: Defines a set of pods (namely those matching + the labelSelector relative to the given namespace(s)) + that this pod should be co-located (affinity) or + not co-located (anti-affinity) with, where co-located + is defined as running on a node whose value of the + label with key matches that of any + node on which a pod of the set of pods is running + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list of + label selector requirements. The requirements + are ANDed. + items: + description: A label selector requirement + is a selector that contains values, a + key, and an operator that relates the + key and values. + properties: + key: + description: key is the label key that + the selector applies to. + type: string + operator: + description: operator represents a key's + relationship to a set of values. Valid + operators are In, NotIn, Exists and + DoesNotExist. + type: string + values: + description: values is an array of string + values. If the operator is In or NotIn, + the values array must be non-empty. + If the operator is Exists or DoesNotExist, + the values array must be empty. This + array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator is + "In", and the values array contains only + "value". The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located (affinity) + or not co-located (anti-affinity) with the pods + matching the labelSelector in the specified + namespaces, where co-located is defined as running + on a node whose value of the label with key + topologyKey matches that of any node on which + any of the selected pods is running. Empty topologyKey + is not allowed. + type: string + required: + - topologyKey + type: object + type: array + type: object + type: object + branch: + properties: + else: + type: string + elseFail: + properties: + failed_node_id: + description: The node id that threw the error. + type: string + message: + description: Error message thrown. + type: string + type: object + elseIf: + items: + properties: + condition: + type: object + then: + type: string + required: + - condition + - then + type: object + type: array + x-kubernetes-list-type: atomic + if: + properties: + condition: + type: object + then: + type: string + required: + - condition + - then + type: object + required: + - if + type: object + config: + description: ConfigMap holds configuration data for pods to + consume. + properties: + apiVersion: + description: 'APIVersion defines the versioned schema of + this representation of an object. Servers should convert + recognized schemas to the latest internal value, and may + reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + type: string + binaryData: + additionalProperties: + format: byte + type: string + description: BinaryData contains the binary data. Each key + must consist of alphanumeric characters, '-', '_' or '.'. + BinaryData can contain byte sequences that are not in + the UTF-8 range. The keys stored in BinaryData must not + overlap with the ones in the Data field, this is enforced + during validation process. Using this field will require + 1.10+ apiserver and kubelet. + type: object + data: + additionalProperties: + type: string + description: Data contains the configuration data. Each + key must consist of alphanumeric characters, '-', '_' + or '.'. Values with non-UTF-8 byte sequences must use + the BinaryData field. The keys stored in Data must not + overlap with the keys in the BinaryData field, this is + enforced during validation process. + type: object + immutable: + description: Immutable, if set to true, ensures that data + stored in the ConfigMap cannot be updated (only object + metadata can be modified). If not set to true, the field + can be modified at any time. Defaulted to nil. This is + a beta field enabled by ImmutableEphemeralVolumes feature + gate. + type: boolean + kind: + description: 'Kind is a string value representing the REST + resource this object represents. Servers may infer this + from the endpoint the client submits requests to. Cannot + be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + type: string + metadata: + description: 'Standard object''s metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata' + properties: + annotations: + additionalProperties: + type: string + type: object + finalizers: + items: + type: string + type: array + labels: + additionalProperties: + type: string + type: object + name: + type: string + namespace: + type: string + type: object + type: object + executionDeadline: + description: Node execution timeout + type: string + hostname: + description: Specifies the hostname of the Pod If not specified, + the pod's hostname will be set to a system-defined value. + type: string + id: + type: string + imagePullSecrets: + description: 'ImagePullSecrets is an optional list of references + to secrets in the same namespace to use for pulling any of + the images used by this PodSpec. If specified, these secrets + will be passed to individual puller implementations for them + to use. For example, in the case of docker, only DockerConfig + type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod' + items: + description: LocalObjectReference contains enough information + to let you locate the referenced object inside the same + namespace. + properties: + name: + description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names + TODO: Add other useful fields. apiVersion, kind, uid?' + type: string + type: object + type: array + x-kubernetes-list-type: atomic + inputBindings: + items: + type: object + type: array + x-kubernetes-list-type: atomic + interruptible: + description: The value set to True means task is OK with getting + interrupted + type: boolean + kind: + description: NodeKind refers to the type of Node. + type: string + name: + type: string + outputAlias: + items: + properties: + alias: + description: A workflow-level unique alias that downstream + nodes can refer to in their input. + type: string + var: + description: Must match one of the output variable names + on a node. + type: string + type: object + type: array + x-kubernetes-list-type: atomic + resources: + description: ResourceRequirements describes the compute resource + requirements. + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + description: 'Limits describes the maximum amount of compute + resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/' + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + description: 'Requests describes the minimum amount of compute + resources required. If Requests is omitted for a container, + it defaults to Limits if that is explicitly specified, + otherwise to an implementation-defined value. More info: + https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/' + type: object + type: object + retry: + description: Strategy to be used to Retry a node that is in + RetryableFailure state + properties: + minAttempts: + description: MinAttempts implies the atleast n attempts + to try this node before giving up. The atleast here is + because we may fail to write the attempt information and + end up retrying again. Also `0` and `1` both mean atleast + one attempt will be done. 0 is a degenerate case. + type: integer + required: + - minAttempts + type: object + schedulerName: + description: If specified, the pod will be dispatched by specified + scheduler. If not specified, the pod will be dispatched by + default scheduler. + type: string + securityContext: + description: 'SecurityContext holds pod-level security attributes + and common container settings. Optional: Defaults to empty. See + type description for default values of each field.' + properties: + fsGroup: + description: "A special supplemental group that applies + to all containers in a pod. Some volume types allow the + Kubelet to change the ownership of that volume to be owned + by the pod: \n 1. The owning GID will be the FSGroup 2. + The setgid bit is set (new files created in the volume + will be owned by FSGroup) 3. The permission bits are OR'd + with rw-rw---- \n If unset, the Kubelet will not modify + the ownership and permissions of any volume." + format: int64 + type: integer + fsGroupChangePolicy: + description: 'fsGroupChangePolicy defines behavior of changing + ownership and permission of the volume before being exposed + inside Pod. This field will only apply to volume types + which support fsGroup based ownership(and permissions). + It will have no effect on ephemeral volume types such + as: secret, configmaps and emptydir. Valid values are + "OnRootMismatch" and "Always". If not specified, "Always" + is used.' + type: string + runAsGroup: + description: The GID to run the entrypoint of the container + process. Uses runtime default if unset. May also be set + in SecurityContext. If set in both SecurityContext and + PodSecurityContext, the value specified in SecurityContext + takes precedence for that container. + format: int64 + type: integer + runAsNonRoot: + description: Indicates that the container must run as a + non-root user. If true, the Kubelet will validate the + image at runtime to ensure that it does not run as UID + 0 (root) and fail to start the container if it does. If + unset or false, no such validation will be performed. + May also be set in SecurityContext. If set in both SecurityContext + and PodSecurityContext, the value specified in SecurityContext + takes precedence. + type: boolean + runAsUser: + description: The UID to run the entrypoint of the container + process. Defaults to user specified in image metadata + if unspecified. May also be set in SecurityContext. If + set in both SecurityContext and PodSecurityContext, the + value specified in SecurityContext takes precedence for + that container. + format: int64 + type: integer + seLinuxOptions: + description: The SELinux context to be applied to all containers. + If unspecified, the container runtime will allocate a + random SELinux context for each container. May also be + set in SecurityContext. If set in both SecurityContext + and PodSecurityContext, the value specified in SecurityContext + takes precedence for that container. + properties: + level: + description: Level is SELinux level label that applies + to the container. + type: string + role: + description: Role is a SELinux role label that applies + to the container. + type: string + type: + description: Type is a SELinux type label that applies + to the container. + type: string + user: + description: User is a SELinux user label that applies + to the container. + type: string + type: object + seccompProfile: + description: The seccomp options to use by the containers + in this pod. + properties: + localhostProfile: + description: localhostProfile indicates a profile defined + in a file on the node should be used. The profile + must be preconfigured on the node to work. Must be + a descending path, relative to the kubelet's configured + seccomp profile location. Must only be set if type + is "Localhost". + type: string + type: + description: "type indicates which kind of seccomp profile + will be applied. Valid options are: \n Localhost - + a profile defined in a file on the node should be + used. RuntimeDefault - the container runtime default + profile should be used. Unconfined - no profile should + be applied." + type: string + required: + - type + type: object + supplementalGroups: + description: A list of groups applied to the first process + run in each container, in addition to the container's + primary GID. If unspecified, no groups will be added + to any container. + items: + format: int64 + type: integer + type: array + sysctls: + description: Sysctls hold a list of namespaced sysctls used + for the pod. Pods with unsupported sysctls (by the container + runtime) might fail to launch. + items: + description: Sysctl defines a kernel parameter to be set + properties: + name: + description: Name of a property to set + type: string + value: + description: Value of a property to set + type: string + required: + - name + - value + type: object + type: array + windowsOptions: + description: The Windows specific settings applied to all + containers. If unspecified, the options within a container's + SecurityContext will be used. If set in both SecurityContext + and PodSecurityContext, the value specified in SecurityContext + takes precedence. + properties: + gmsaCredentialSpec: + description: GMSACredentialSpec is where the GMSA admission + webhook (https://github.com/kubernetes-sigs/windows-gmsa) + inlines the contents of the GMSA credential spec named + by the GMSACredentialSpecName field. + type: string + gmsaCredentialSpecName: + description: GMSACredentialSpecName is the name of the + GMSA credential spec to use. + type: string + runAsUserName: + description: The UserName in Windows to run the entrypoint + of the container process. Defaults to the user specified + in image metadata if unspecified. May also be set + in PodSecurityContext. If set in both SecurityContext + and PodSecurityContext, the value specified in SecurityContext + takes precedence. + type: string + type: object + type: object + subdomain: + description: If specified, the fully qualified Pod hostname + will be "...svc.". If not specified, the pod will not have a domainname + at all. + type: string + task: + type: string + tolerations: + description: If specified, the pod's tolerations. + items: + description: The pod this Toleration is attached to tolerates + any taint that matches the triple using + the matching operator . + properties: + effect: + description: Effect indicates the taint effect to match. + Empty means match all taint effects. When specified, + allowed values are NoSchedule, PreferNoSchedule and + NoExecute. + type: string + key: + description: Key is the taint key that the toleration + applies to. Empty means match all taint keys. If the + key is empty, operator must be Exists; this combination + means to match all values and all keys. + type: string + operator: + description: Operator represents a key's relationship + to the value. Valid operators are Exists and Equal. + Defaults to Equal. Exists is equivalent to wildcard + for value, so that a pod can tolerate all taints of + a particular category. + type: string + tolerationSeconds: + description: TolerationSeconds represents the period of + time the toleration (which must be of effect NoExecute, + otherwise this field is ignored) tolerates the taint. + By default, it is not set, which means tolerate the + taint forever (do not evict). Zero and negative values + will be treated as 0 (evict immediately) by the system. + format: int64 + type: integer + value: + description: Value is the taint value the toleration matches + to. If the operator is Exists, the value should be empty, + otherwise just a regular string. + type: string + type: object + type: array + x-kubernetes-list-type: atomic + workflow: + properties: + launchPlanRefId: + description: Either one of the two + properties: + domain: + description: Name of the domain the resource belongs + to. A domain can be considered as a subset within + a specific project. + type: string + name: + description: User provided value for the resource. + type: string + project: + description: Name of the project the resource belongs + to. + type: string + resource_type: + description: Identifies the specific type of resource + that this identifier corresponds to. + format: int32 + type: integer + version: + description: Specific version of the resource. + type: string + type: object + subWorkflowRef: + description: 'We currently want the SubWorkflow to be completely + contained in the node. this is because We use the node + status to store the information of the execution. Important + Note: This may cause a bloat in case we use the same SubWorkflow + in multiple nodes. The recommended technique for that + is to use launch plan refs. This is because we will end + up executing the launch plan refs as disparate executions + in Flyte propeller. This is potentially better as it prevents + us from hitting the storage limit in etcd Workflow *WorkflowSpec + `json:"workflow,omitempty"`' + type: string + type: object + required: + - id + - kind + type: object + type: object + onFailure: + description: Defines a single node to execute in case the system determined + the Workflow has failed. + properties: + activeDeadline: + description: StartTime before the system will actively try to + mark it failed and kill associated containers. Value must be + a positive integer. This includes time spent waiting in the + queue. + type: string + affinity: + description: If specified, the pod's scheduling constraints + properties: + nodeAffinity: + description: Describes node affinity scheduling rules for + the pod. + properties: + preferredDuringSchedulingIgnoredDuringExecution: + description: The scheduler will prefer to schedule pods + to nodes that satisfy the affinity expressions specified + by this field, but it may choose a node that violates + one or more of the expressions. The node that is most + preferred is the one with the greatest sum of weights, + i.e. for each node that meets all of the scheduling + requirements (resource request, requiredDuringScheduling + affinity expressions, etc.), compute a sum by iterating + through the elements of this field and adding "weight" + to the sum if the node matches the corresponding matchExpressions; + the node(s) with the highest sum are the most preferred. + items: + description: An empty preferred scheduling term matches + all objects with implicit weight 0 (i.e. it's a no-op). + A null preferred scheduling term matches no objects + (i.e. is also a no-op). + properties: + preference: + description: A node selector term, associated with + the corresponding weight. + properties: + matchExpressions: + description: A list of node selector requirements + by node's labels. + items: + description: A node selector requirement is + a selector that contains values, a key, + and an operator that relates the key and + values. + properties: + key: + description: The label key that the selector + applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, the + values array must be non-empty. If the + operator is Exists or DoesNotExist, + the values array must be empty. If the + operator is Gt or Lt, the values array + must have a single element, which will + be interpreted as an integer. This array + is replaced during a strategic merge + patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchFields: + description: A list of node selector requirements + by node's fields. + items: + description: A node selector requirement is + a selector that contains values, a key, + and an operator that relates the key and + values. + properties: + key: + description: The label key that the selector + applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, the + values array must be non-empty. If the + operator is Exists or DoesNotExist, + the values array must be empty. If the + operator is Gt or Lt, the values array + must have a single element, which will + be interpreted as an integer. This array + is replaced during a strategic merge + patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + type: object + weight: + description: Weight associated with matching the + corresponding nodeSelectorTerm, in the range 1-100. + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + requiredDuringSchedulingIgnoredDuringExecution: + description: If the affinity requirements specified by + this field are not met at scheduling time, the pod will + not be scheduled onto the node. If the affinity requirements + specified by this field cease to be met at some point + during pod execution (e.g. due to an update), the system + may or may not try to eventually evict the pod from + its node. + properties: + nodeSelectorTerms: + description: Required. A list of node selector terms. + The terms are ORed. + items: + description: A null or empty node selector term + matches no objects. The requirements of them are + ANDed. The TopologySelectorTerm type implements + a subset of the NodeSelectorTerm. + properties: + matchExpressions: + description: A list of node selector requirements + by node's labels. + items: + description: A node selector requirement is + a selector that contains values, a key, + and an operator that relates the key and + values. + properties: + key: + description: The label key that the selector + applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, the + values array must be non-empty. If the + operator is Exists or DoesNotExist, + the values array must be empty. If the + operator is Gt or Lt, the values array + must have a single element, which will + be interpreted as an integer. This array + is replaced during a strategic merge + patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchFields: + description: A list of node selector requirements + by node's fields. + items: + description: A node selector requirement is + a selector that contains values, a key, + and an operator that relates the key and + values. + properties: + key: + description: The label key that the selector + applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, the + values array must be non-empty. If the + operator is Exists or DoesNotExist, + the values array must be empty. If the + operator is Gt or Lt, the values array + must have a single element, which will + be interpreted as an integer. This array + is replaced during a strategic merge + patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + type: object + type: array + required: + - nodeSelectorTerms + type: object + type: object + podAffinity: + description: Describes pod affinity scheduling rules (e.g. + co-locate this pod in the same node, zone, etc. as some + other pod(s)). + properties: + preferredDuringSchedulingIgnoredDuringExecution: + description: The scheduler will prefer to schedule pods + to nodes that satisfy the affinity expressions specified + by this field, but it may choose a node that violates + one or more of the expressions. The node that is most + preferred is the one with the greatest sum of weights, + i.e. for each node that meets all of the scheduling + requirements (resource request, requiredDuringScheduling + affinity expressions, etc.), compute a sum by iterating + through the elements of this field and adding "weight" + to the sum if the node has pods which matches the corresponding + podAffinityTerm; the node(s) with the highest sum are + the most preferred. + items: + description: The weights of all of the matched WeightedPodAffinityTerm + fields are added per-node to find the most preferred + node(s) + properties: + podAffinityTerm: + description: Required. A pod affinity term, associated + with the corresponding weight. + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list + of label selector requirements. The requirements + are ANDed. + items: + description: A label selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: key is the label key + that the selector applies to. + type: string + operator: + description: operator represents a + key's relationship to a set of values. + Valid operators are In, NotIn, Exists + and DoesNotExist. + type: string + values: + description: values is an array of + string values. If the operator is + In or NotIn, the values array must + be non-empty. If the operator is + Exists or DoesNotExist, the values + array must be empty. This array + is replaced during a strategic merge + patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator + is "In", and the values array contains + only "value". The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located (affinity) + or not co-located (anti-affinity) with the + pods matching the labelSelector in the specified + namespaces, where co-located is defined as + running on a node whose value of the label + with key topologyKey matches that of any node + on which any of the selected pods is running. + Empty topologyKey is not allowed. + type: string + required: + - topologyKey + type: object + weight: + description: weight associated with matching the + corresponding podAffinityTerm, in the range 1-100. + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + requiredDuringSchedulingIgnoredDuringExecution: + description: If the affinity requirements specified by + this field are not met at scheduling time, the pod will + not be scheduled onto the node. If the affinity requirements + specified by this field cease to be met at some point + during pod execution (e.g. due to a pod label update), + the system may or may not try to eventually evict the + pod from its node. When there are multiple elements, + the lists of nodes corresponding to each podAffinityTerm + are intersected, i.e. all terms must be satisfied. + items: + description: Defines a set of pods (namely those matching + the labelSelector relative to the given namespace(s)) + that this pod should be co-located (affinity) or not + co-located (anti-affinity) with, where co-located + is defined as running on a node whose value of the + label with key matches that of any node + on which a pod of the set of pods is running + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list of label + selector requirements. The requirements are + ANDed. + items: + description: A label selector requirement + is a selector that contains values, a key, + and an operator that relates the key and + values. + properties: + key: + description: key is the label key that + the selector applies to. + type: string + operator: + description: operator represents a key's + relationship to a set of values. Valid + operators are In, NotIn, Exists and + DoesNotExist. + type: string + values: + description: values is an array of string + values. If the operator is In or NotIn, + the values array must be non-empty. + If the operator is Exists or DoesNotExist, + the values array must be empty. This + array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator is + "In", and the values array contains only "value". + The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located (affinity) + or not co-located (anti-affinity) with the pods + matching the labelSelector in the specified namespaces, + where co-located is defined as running on a node + whose value of the label with key topologyKey + matches that of any node on which any of the selected + pods is running. Empty topologyKey is not allowed. + type: string + required: + - topologyKey + type: object + type: array + type: object + podAntiAffinity: + description: Describes pod anti-affinity scheduling rules + (e.g. avoid putting this pod in the same node, zone, etc. + as some other pod(s)). + properties: + preferredDuringSchedulingIgnoredDuringExecution: + description: The scheduler will prefer to schedule pods + to nodes that satisfy the anti-affinity expressions + specified by this field, but it may choose a node that + violates one or more of the expressions. The node that + is most preferred is the one with the greatest sum of + weights, i.e. for each node that meets all of the scheduling + requirements (resource request, requiredDuringScheduling + anti-affinity expressions, etc.), compute a sum by iterating + through the elements of this field and adding "weight" + to the sum if the node has pods which matches the corresponding + podAffinityTerm; the node(s) with the highest sum are + the most preferred. + items: + description: The weights of all of the matched WeightedPodAffinityTerm + fields are added per-node to find the most preferred + node(s) + properties: + podAffinityTerm: + description: Required. A pod affinity term, associated + with the corresponding weight. + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list + of label selector requirements. The requirements + are ANDed. + items: + description: A label selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: key is the label key + that the selector applies to. + type: string + operator: + description: operator represents a + key's relationship to a set of values. + Valid operators are In, NotIn, Exists + and DoesNotExist. + type: string + values: + description: values is an array of + string values. If the operator is + In or NotIn, the values array must + be non-empty. If the operator is + Exists or DoesNotExist, the values + array must be empty. This array + is replaced during a strategic merge + patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator + is "In", and the values array contains + only "value". The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located (affinity) + or not co-located (anti-affinity) with the + pods matching the labelSelector in the specified + namespaces, where co-located is defined as + running on a node whose value of the label + with key topologyKey matches that of any node + on which any of the selected pods is running. + Empty topologyKey is not allowed. + type: string + required: + - topologyKey + type: object + weight: + description: weight associated with matching the + corresponding podAffinityTerm, in the range 1-100. + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + requiredDuringSchedulingIgnoredDuringExecution: + description: If the anti-affinity requirements specified + by this field are not met at scheduling time, the pod + will not be scheduled onto the node. If the anti-affinity + requirements specified by this field cease to be met + at some point during pod execution (e.g. due to a pod + label update), the system may or may not try to eventually + evict the pod from its node. When there are multiple + elements, the lists of nodes corresponding to each podAffinityTerm + are intersected, i.e. all terms must be satisfied. + items: + description: Defines a set of pods (namely those matching + the labelSelector relative to the given namespace(s)) + that this pod should be co-located (affinity) or not + co-located (anti-affinity) with, where co-located + is defined as running on a node whose value of the + label with key matches that of any node + on which a pod of the set of pods is running + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list of label + selector requirements. The requirements are + ANDed. + items: + description: A label selector requirement + is a selector that contains values, a key, + and an operator that relates the key and + values. + properties: + key: + description: key is the label key that + the selector applies to. + type: string + operator: + description: operator represents a key's + relationship to a set of values. Valid + operators are In, NotIn, Exists and + DoesNotExist. + type: string + values: + description: values is an array of string + values. If the operator is In or NotIn, + the values array must be non-empty. + If the operator is Exists or DoesNotExist, + the values array must be empty. This + array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator is + "In", and the values array contains only "value". + The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located (affinity) + or not co-located (anti-affinity) with the pods + matching the labelSelector in the specified namespaces, + where co-located is defined as running on a node + whose value of the label with key topologyKey + matches that of any node on which any of the selected + pods is running. Empty topologyKey is not allowed. + type: string + required: + - topologyKey + type: object + type: array + type: object + type: object + branch: + properties: + else: + type: string + elseFail: + properties: + failed_node_id: + description: The node id that threw the error. + type: string + message: + description: Error message thrown. + type: string + type: object + elseIf: + items: + properties: + condition: + type: object + then: + type: string + required: + - condition + - then + type: object + type: array + x-kubernetes-list-type: atomic + if: + properties: + condition: + type: object + then: + type: string + required: + - condition + - then + type: object + required: + - if + type: object + config: + description: ConfigMap holds configuration data for pods to consume. + properties: + apiVersion: + description: 'APIVersion defines the versioned schema of this + representation of an object. Servers should convert recognized + schemas to the latest internal value, and may reject unrecognized + values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + type: string + binaryData: + additionalProperties: + format: byte + type: string + description: BinaryData contains the binary data. Each key + must consist of alphanumeric characters, '-', '_' or '.'. + BinaryData can contain byte sequences that are not in the + UTF-8 range. The keys stored in BinaryData must not overlap + with the ones in the Data field, this is enforced during + validation process. Using this field will require 1.10+ + apiserver and kubelet. + type: object + data: + additionalProperties: + type: string + description: Data contains the configuration data. Each key + must consist of alphanumeric characters, '-', '_' or '.'. + Values with non-UTF-8 byte sequences must use the BinaryData + field. The keys stored in Data must not overlap with the + keys in the BinaryData field, this is enforced during validation + process. + type: object + immutable: + description: Immutable, if set to true, ensures that data + stored in the ConfigMap cannot be updated (only object metadata + can be modified). If not set to true, the field can be modified + at any time. Defaulted to nil. This is a beta field enabled + by ImmutableEphemeralVolumes feature gate. + type: boolean + kind: + description: 'Kind is a string value representing the REST + resource this object represents. Servers may infer this + from the endpoint the client submits requests to. Cannot + be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + type: string + metadata: + description: 'Standard object''s metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata' + properties: + annotations: + additionalProperties: + type: string + type: object + finalizers: + items: + type: string + type: array + labels: + additionalProperties: + type: string + type: object + name: + type: string + namespace: + type: string + type: object + type: object + executionDeadline: + description: Node execution timeout + type: string + hostname: + description: Specifies the hostname of the Pod If not specified, + the pod's hostname will be set to a system-defined value. + type: string + id: + type: string + imagePullSecrets: + description: 'ImagePullSecrets is an optional list of references + to secrets in the same namespace to use for pulling any of the + images used by this PodSpec. If specified, these secrets will + be passed to individual puller implementations for them to use. + For example, in the case of docker, only DockerConfig type secrets + are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod' + items: + description: LocalObjectReference contains enough information + to let you locate the referenced object inside the same namespace. + properties: + name: + description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names + TODO: Add other useful fields. apiVersion, kind, uid?' + type: string + type: object + type: array + x-kubernetes-list-type: atomic + inputBindings: + items: + type: object + type: array + x-kubernetes-list-type: atomic + interruptible: + description: The value set to True means task is OK with getting + interrupted + type: boolean + kind: + description: NodeKind refers to the type of Node. + type: string + name: + type: string + outputAlias: + items: + properties: + alias: + description: A workflow-level unique alias that downstream + nodes can refer to in their input. + type: string + var: + description: Must match one of the output variable names + on a node. + type: string + type: object + type: array + x-kubernetes-list-type: atomic + resources: + description: ResourceRequirements describes the compute resource + requirements. + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + description: 'Limits describes the maximum amount of compute + resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/' + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + description: 'Requests describes the minimum amount of compute + resources required. If Requests is omitted for a container, + it defaults to Limits if that is explicitly specified, otherwise + to an implementation-defined value. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/' + type: object + type: object + retry: + description: Strategy to be used to Retry a node that is in RetryableFailure + state + properties: + minAttempts: + description: MinAttempts implies the atleast n attempts to + try this node before giving up. The atleast here is because + we may fail to write the attempt information and end up + retrying again. Also `0` and `1` both mean atleast one attempt + will be done. 0 is a degenerate case. + type: integer + required: + - minAttempts + type: object + schedulerName: + description: If specified, the pod will be dispatched by specified + scheduler. If not specified, the pod will be dispatched by default + scheduler. + type: string + securityContext: + description: 'SecurityContext holds pod-level security attributes + and common container settings. Optional: Defaults to empty. See + type description for default values of each field.' + properties: + fsGroup: + description: "A special supplemental group that applies to + all containers in a pod. Some volume types allow the Kubelet + to change the ownership of that volume to be owned by the + pod: \n 1. The owning GID will be the FSGroup 2. The setgid + bit is set (new files created in the volume will be owned + by FSGroup) 3. The permission bits are OR'd with rw-rw---- + \n If unset, the Kubelet will not modify the ownership and + permissions of any volume." + format: int64 + type: integer + fsGroupChangePolicy: + description: 'fsGroupChangePolicy defines behavior of changing + ownership and permission of the volume before being exposed + inside Pod. This field will only apply to volume types which + support fsGroup based ownership(and permissions). It will + have no effect on ephemeral volume types such as: secret, + configmaps and emptydir. Valid values are "OnRootMismatch" + and "Always". If not specified, "Always" is used.' + type: string + runAsGroup: + description: The GID to run the entrypoint of the container + process. Uses runtime default if unset. May also be set + in SecurityContext. If set in both SecurityContext and + PodSecurityContext, the value specified in SecurityContext + takes precedence for that container. + format: int64 + type: integer + runAsNonRoot: + description: Indicates that the container must run as a non-root + user. If true, the Kubelet will validate the image at runtime + to ensure that it does not run as UID 0 (root) and fail + to start the container if it does. If unset or false, no + such validation will be performed. May also be set in SecurityContext. If + set in both SecurityContext and PodSecurityContext, the + value specified in SecurityContext takes precedence. + type: boolean + runAsUser: + description: The UID to run the entrypoint of the container + process. Defaults to user specified in image metadata if + unspecified. May also be set in SecurityContext. If set + in both SecurityContext and PodSecurityContext, the value + specified in SecurityContext takes precedence for that container. + format: int64 + type: integer + seLinuxOptions: + description: The SELinux context to be applied to all containers. + If unspecified, the container runtime will allocate a random + SELinux context for each container. May also be set in + SecurityContext. If set in both SecurityContext and PodSecurityContext, + the value specified in SecurityContext takes precedence + for that container. + properties: + level: + description: Level is SELinux level label that applies + to the container. + type: string + role: + description: Role is a SELinux role label that applies + to the container. + type: string + type: + description: Type is a SELinux type label that applies + to the container. + type: string + user: + description: User is a SELinux user label that applies + to the container. + type: string + type: object + seccompProfile: + description: The seccomp options to use by the containers + in this pod. + properties: + localhostProfile: + description: localhostProfile indicates a profile defined + in a file on the node should be used. The profile must + be preconfigured on the node to work. Must be a descending + path, relative to the kubelet's configured seccomp profile + location. Must only be set if type is "Localhost". + type: string + type: + description: "type indicates which kind of seccomp profile + will be applied. Valid options are: \n Localhost - a + profile defined in a file on the node should be used. + RuntimeDefault - the container runtime default profile + should be used. Unconfined - no profile should be applied." + type: string + required: + - type + type: object + supplementalGroups: + description: A list of groups applied to the first process + run in each container, in addition to the container's primary + GID. If unspecified, no groups will be added to any container. + items: + format: int64 + type: integer + type: array + sysctls: + description: Sysctls hold a list of namespaced sysctls used + for the pod. Pods with unsupported sysctls (by the container + runtime) might fail to launch. + items: + description: Sysctl defines a kernel parameter to be set + properties: + name: + description: Name of a property to set + type: string + value: + description: Value of a property to set + type: string + required: + - name + - value + type: object + type: array + windowsOptions: + description: The Windows specific settings applied to all + containers. If unspecified, the options within a container's + SecurityContext will be used. If set in both SecurityContext + and PodSecurityContext, the value specified in SecurityContext + takes precedence. + properties: + gmsaCredentialSpec: + description: GMSACredentialSpec is where the GMSA admission + webhook (https://github.com/kubernetes-sigs/windows-gmsa) + inlines the contents of the GMSA credential spec named + by the GMSACredentialSpecName field. + type: string + gmsaCredentialSpecName: + description: GMSACredentialSpecName is the name of the + GMSA credential spec to use. + type: string + runAsUserName: + description: The UserName in Windows to run the entrypoint + of the container process. Defaults to the user specified + in image metadata if unspecified. May also be set in + PodSecurityContext. If set in both SecurityContext and + PodSecurityContext, the value specified in SecurityContext + takes precedence. + type: string + type: object + type: object + subdomain: + description: If specified, the fully qualified Pod hostname will + be "...svc.". + If not specified, the pod will not have a domainname at all. + type: string + task: + type: string + tolerations: + description: If specified, the pod's tolerations. + items: + description: The pod this Toleration is attached to tolerates + any taint that matches the triple using + the matching operator . + properties: + effect: + description: Effect indicates the taint effect to match. + Empty means match all taint effects. When specified, allowed + values are NoSchedule, PreferNoSchedule and NoExecute. + type: string + key: + description: Key is the taint key that the toleration applies + to. Empty means match all taint keys. If the key is empty, + operator must be Exists; this combination means to match + all values and all keys. + type: string + operator: + description: Operator represents a key's relationship to + the value. Valid operators are Exists and Equal. Defaults + to Equal. Exists is equivalent to wildcard for value, + so that a pod can tolerate all taints of a particular + category. + type: string + tolerationSeconds: + description: TolerationSeconds represents the period of + time the toleration (which must be of effect NoExecute, + otherwise this field is ignored) tolerates the taint. + By default, it is not set, which means tolerate the taint + forever (do not evict). Zero and negative values will + be treated as 0 (evict immediately) by the system. + format: int64 + type: integer + value: + description: Value is the taint value the toleration matches + to. If the operator is Exists, the value should be empty, + otherwise just a regular string. + type: string + type: object + type: array + x-kubernetes-list-type: atomic + workflow: + properties: + launchPlanRefId: + description: Either one of the two + properties: + domain: + description: Name of the domain the resource belongs to. + A domain can be considered as a subset within a specific + project. + type: string + name: + description: User provided value for the resource. + type: string + project: + description: Name of the project the resource belongs + to. + type: string + resource_type: + description: Identifies the specific type of resource + that this identifier corresponds to. + format: int32 + type: integer + version: + description: Specific version of the resource. + type: string + type: object + subWorkflowRef: + description: 'We currently want the SubWorkflow to be completely + contained in the node. this is because We use the node status + to store the information of the execution. Important Note: + This may cause a bloat in case we use the same SubWorkflow + in multiple nodes. The recommended technique for that is + to use launch plan refs. This is because we will end up + executing the launch plan refs as disparate executions in + Flyte propeller. This is potentially better as it prevents + us from hitting the storage limit in etcd Workflow *WorkflowSpec + `json:"workflow,omitempty"`' + type: string + type: object + required: + - id + - kind + type: object + onFailurePolicy: + description: Defines the policy for handling failures whether it's + to fail immediately, or let the nodes run to completion. + format: int32 + type: integer + outputBindings: + description: Defines the data links used to construct the final outputs + of the workflow. Bindings will typically refer to specific outputs + of a subset of the nodes executed in the Workflow. When executing + the end-node, the execution engine will traverse these bindings + and assemble the final set of outputs of the workflow. + items: + type: object + type: array + x-kubernetes-list-type: atomic + outputs: + description: Defines the declaration of the outputs types and names + this workflow is expected to generate. + type: object + required: + - connections + - edges + - id + - nodes + type: object + status: + description: Status is the only mutable section in the workflow. It holds + all the execution information + properties: + dataDir: + description: Defines a reference to data location. + type: string + error: + description: Stores the Error during the Execution of the Workflow. + It is optional and usually associated with Failing/Failed state + only + properties: + code: + description: 'Error code indicates a grouping of a type of error. + More Info: ' + type: string + error_uri: + description: Full error contents accessible via a URI + type: string + kind: + description: 'Error type: System or User' + format: int32 + type: integer + message: + description: Detailed description of the error - including stack + trace. + type: string + type: object + failedAttempts: + description: Number of Attempts completed with rounds resulting in + error. this is used to cap out poison pill workflows that spin in + an error loop. The value should be set at the global level and will + be enforced. At the end of the retries the workflow will fail + format: int32 + type: integer + lastUpdatedAt: + format: date-time + type: string + message: + type: string + nodeStatus: + additionalProperties: + properties: + attempts: + format: int32 + type: integer + branchStatus: + properties: + finalNodeId: + type: string + phase: + description: A branchNode has its own Phases. These are + used by the child nodes to ensure that the branch node + is in the right state + type: integer + type: object + cached: + type: boolean + dynamicNodeStatus: + properties: + error: + description: Wrapper around core.Execution error. Execution + Error has a protobuf enum and hence needs to be wrapped + by custom marshaller + properties: + code: + description: 'Error code indicates a grouping of a type + of error. More Info: ' + type: string + error_uri: + description: Full error contents accessible via a URI + type: string + kind: + description: 'Error type: System or User' + format: int32 + type: integer + message: + description: Detailed description of the error - including + stack trace. + type: string + type: object + phase: + type: integer + reason: + type: string + type: object + error: + description: In case of Failing/Failed Phase, an execution error + can be optionally associated with the Node + properties: + code: + description: 'Error code indicates a grouping of a type + of error. More Info: ' + type: string + error_uri: + description: Full error contents accessible via a URI + type: string + kind: + description: 'Error type: System or User' + format: int32 + type: integer + message: + description: Detailed description of the error - including + stack trace. + type: string + type: object + laStartedAt: + format: date-time + type: string + lastUpdatedAt: + format: date-time + type: string + message: + type: string + pState: + format: byte + type: string + parentNode: + description: This is useful only for branch nodes. If this is + set, then it can be used to determine if execution can proceed + type: string + phase: + type: integer + phaseVersion: + format: int32 + type: integer + psv: + format: int32 + type: integer + queuedAt: + format: date-time + type: string + startedAt: + format: date-time + type: string + stoppedAt: + format: date-time + type: string + subNodeStatus: + additionalProperties: true + type: object + systemFailures: + format: int32 + type: integer + tick: + format: int32 + type: integer + updAt: + description: "A Time represents an instant in time with nanosecond + precision. \n Programs using times should typically store + and pass them as values, not pointers. That is, time variables + and struct fields should be of type time.Time, not *time.Time. + \n A Time value can be used by multiple goroutines simultaneously + except that the methods GobDecode, UnmarshalBinary, UnmarshalJSON + and UnmarshalText are not concurrency-safe. \n Time instants + can be compared using the Before, After, and Equal methods. + The Sub method subtracts two instants, producing a Duration. + The Add method adds a Time and a Duration, producing a Time. + \n The zero value of type Time is January 1, year 1, 00:00:00.000000000 + UTC. As this time is unlikely to come up in practice, the + IsZero method gives a simple way of detecting a time that + has not been initialized explicitly. \n Each Time has associated + with it a Location, consulted when computing the presentation + form of the time, such as in the Format, Hour, and Year methods. + The methods Local, UTC, and In return a Time with a specific + location. Changing the location in this way changes only the + presentation; it does not change the instant in time being + denoted and therefore does not affect the computations described + in earlier paragraphs. \n Representations of a Time value + saved by the GobEncode, MarshalBinary, MarshalJSON, and MarshalText + methods store the Time.Location's offset, but not the location + name. They therefore lose information about Daylight Saving + Time. \n In addition to the required “wall clock” reading, + a Time may contain an optional reading of the current process's + monotonic clock, to provide additional precision for comparison + or subtraction. See the “Monotonic Clocks” section in the + package documentation for details. \n Note that the Go == + operator compares not just the time instant but also the Location + and the monotonic clock reading. Therefore, Time values should + not be used as map or database keys without first guaranteeing + that the identical Location has been set for all values, which + can be achieved through use of the UTC or Local method, and + that the monotonic clock reading has been stripped by setting + t = t.Round(0). In general, prefer t.Equal(u) to t == u, since + t.Equal uses the most accurate comparison available and correctly + handles the case when only one of its arguments has a monotonic + clock reading." + type: object + workflowNodeStatus: + description: TODO not used delete + properties: + executionError: + description: Represents the error message from the execution. + properties: + code: + description: 'Error code indicates a grouping of a type + of error. More Info: ' + type: string + error_uri: + description: Full error contents accessible via a URI + type: string + kind: + description: 'Error type: System or User' + format: int32 + type: integer + message: + description: Detailed description of the error - including + stack trace. + type: string + type: object + phase: + type: integer + type: object + type: object + type: object + outputRef: + description: Defines a reference to data location. + type: string + phase: + description: WorkflowPhase indicates current state of the Workflow. + type: integer + startedAt: + format: date-time + type: string + stoppedAt: + format: date-time + type: string + required: + - phase + type: object + subWorkflows: + additionalProperties: + description: WorkflowSpec is the spec for the actual Flyte Workflow + (DAG) + properties: + connections: + description: 'Defines the set of connections (both data dependencies + and execution dependencies) that the graph is formed of. The execution + engine will respect and follow these connections as it determines + which nodes can and should be executed. Deprecated: Please use + Connections' + properties: + DownstreamEdges: + additionalProperties: + items: + type: string + type: array + type: object + UpstreamEdges: + additionalProperties: + items: + type: string + type: array + type: object + type: object + edges: + description: Defines the set of connections (both data dependencies + and execution dependencies) that the graph is formed of. The execution + engine will respect and follow these connections as it determines + which nodes can and should be executed. + properties: + downstream: + additionalProperties: + items: + type: string + type: array + type: object + upstream: + additionalProperties: + items: + type: string + type: array + type: object + required: + - downstream + - upstream + type: object + id: + type: string + nodes: + additionalProperties: + properties: + activeDeadline: + description: StartTime before the system will actively try + to mark it failed and kill associated containers. Value + must be a positive integer. This includes time spent waiting + in the queue. + type: string + affinity: + description: If specified, the pod's scheduling constraints + properties: + nodeAffinity: + description: Describes node affinity scheduling rules + for the pod. + properties: + preferredDuringSchedulingIgnoredDuringExecution: + description: The scheduler will prefer to schedule + pods to nodes that satisfy the affinity expressions + specified by this field, but it may choose a node + that violates one or more of the expressions. The + node that is most preferred is the one with the + greatest sum of weights, i.e. for each node that + meets all of the scheduling requirements (resource + request, requiredDuringScheduling affinity expressions, + etc.), compute a sum by iterating through the elements + of this field and adding "weight" to the sum if + the node matches the corresponding matchExpressions; + the node(s) with the highest sum are the most preferred. + items: + description: An empty preferred scheduling term + matches all objects with implicit weight 0 (i.e. + it's a no-op). A null preferred scheduling term + matches no objects (i.e. is also a no-op). + properties: + preference: + description: A node selector term, associated + with the corresponding weight. + properties: + matchExpressions: + description: A list of node selector requirements + by node's labels. + items: + description: A node selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: The label key that the + selector applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, + the values array must be non-empty. + If the operator is Exists or DoesNotExist, + the values array must be empty. + If the operator is Gt or Lt, the + values array must have a single + element, which will be interpreted + as an integer. This array is replaced + during a strategic merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchFields: + description: A list of node selector requirements + by node's fields. + items: + description: A node selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: The label key that the + selector applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, + the values array must be non-empty. + If the operator is Exists or DoesNotExist, + the values array must be empty. + If the operator is Gt or Lt, the + values array must have a single + element, which will be interpreted + as an integer. This array is replaced + during a strategic merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + type: object + weight: + description: Weight associated with matching + the corresponding nodeSelectorTerm, in the + range 1-100. + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + requiredDuringSchedulingIgnoredDuringExecution: + description: If the affinity requirements specified + by this field are not met at scheduling time, the + pod will not be scheduled onto the node. If the + affinity requirements specified by this field cease + to be met at some point during pod execution (e.g. + due to an update), the system may or may not try + to eventually evict the pod from its node. + properties: + nodeSelectorTerms: + description: Required. A list of node selector + terms. The terms are ORed. + items: + description: A null or empty node selector term + matches no objects. The requirements of them + are ANDed. The TopologySelectorTerm type implements + a subset of the NodeSelectorTerm. + properties: + matchExpressions: + description: A list of node selector requirements + by node's labels. + items: + description: A node selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: The label key that the + selector applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, + the values array must be non-empty. + If the operator is Exists or DoesNotExist, + the values array must be empty. + If the operator is Gt or Lt, the + values array must have a single + element, which will be interpreted + as an integer. This array is replaced + during a strategic merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchFields: + description: A list of node selector requirements + by node's fields. + items: + description: A node selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: The label key that the + selector applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, + the values array must be non-empty. + If the operator is Exists or DoesNotExist, + the values array must be empty. + If the operator is Gt or Lt, the + values array must have a single + element, which will be interpreted + as an integer. This array is replaced + during a strategic merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + type: object + type: array + required: + - nodeSelectorTerms + type: object + type: object + podAffinity: + description: Describes pod affinity scheduling rules (e.g. + co-locate this pod in the same node, zone, etc. as some + other pod(s)). + properties: + preferredDuringSchedulingIgnoredDuringExecution: + description: The scheduler will prefer to schedule + pods to nodes that satisfy the affinity expressions + specified by this field, but it may choose a node + that violates one or more of the expressions. The + node that is most preferred is the one with the + greatest sum of weights, i.e. for each node that + meets all of the scheduling requirements (resource + request, requiredDuringScheduling affinity expressions, + etc.), compute a sum by iterating through the elements + of this field and adding "weight" to the sum if + the node has pods which matches the corresponding + podAffinityTerm; the node(s) with the highest sum + are the most preferred. + items: + description: The weights of all of the matched WeightedPodAffinityTerm + fields are added per-node to find the most preferred + node(s) + properties: + podAffinityTerm: + description: Required. A pod affinity term, + associated with the corresponding weight. + properties: + labelSelector: + description: A label query over a set of + resources, in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list + of label selector requirements. The + requirements are ANDed. + items: + description: A label selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: key is the label + key that the selector applies + to. + type: string + operator: + description: operator represents + a key's relationship to a set + of values. Valid operators are + In, NotIn, Exists and DoesNotExist. + type: string + values: + description: values is an array + of string values. If the operator + is In or NotIn, the values array + must be non-empty. If the operator + is Exists or DoesNotExist, the + values array must be empty. + This array is replaced during + a strategic merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of + {key,value} pairs. A single {key,value} + in the matchLabels map is equivalent + to an element of matchExpressions, + whose key field is "key", the operator + is "In", and the values array contains + only "value". The requirements are + ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which + namespaces the labelSelector applies to + (matches against); null or empty list + means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located + (affinity) or not co-located (anti-affinity) + with the pods matching the labelSelector + in the specified namespaces, where co-located + is defined as running on a node whose + value of the label with key topologyKey + matches that of any node on which any + of the selected pods is running. Empty + topologyKey is not allowed. + type: string + required: + - topologyKey + type: object + weight: + description: weight associated with matching + the corresponding podAffinityTerm, in the + range 1-100. + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + requiredDuringSchedulingIgnoredDuringExecution: + description: If the affinity requirements specified + by this field are not met at scheduling time, the + pod will not be scheduled onto the node. If the + affinity requirements specified by this field cease + to be met at some point during pod execution (e.g. + due to a pod label update), the system may or may + not try to eventually evict the pod from its node. + When there are multiple elements, the lists of nodes + corresponding to each podAffinityTerm are intersected, + i.e. all terms must be satisfied. + items: + description: Defines a set of pods (namely those + matching the labelSelector relative to the given + namespace(s)) that this pod should be co-located + (affinity) or not co-located (anti-affinity) with, + where co-located is defined as running on a node + whose value of the label with key + matches that of any node on which a pod of the + set of pods is running + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list + of label selector requirements. The requirements + are ANDed. + items: + description: A label selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: key is the label key + that the selector applies to. + type: string + operator: + description: operator represents a + key's relationship to a set of values. + Valid operators are In, NotIn, Exists + and DoesNotExist. + type: string + values: + description: values is an array of + string values. If the operator is + In or NotIn, the values array must + be non-empty. If the operator is + Exists or DoesNotExist, the values + array must be empty. This array + is replaced during a strategic merge + patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator + is "In", and the values array contains + only "value". The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located (affinity) + or not co-located (anti-affinity) with the + pods matching the labelSelector in the specified + namespaces, where co-located is defined as + running on a node whose value of the label + with key topologyKey matches that of any node + on which any of the selected pods is running. + Empty topologyKey is not allowed. + type: string + required: + - topologyKey + type: object + type: array + type: object + podAntiAffinity: + description: Describes pod anti-affinity scheduling rules + (e.g. avoid putting this pod in the same node, zone, + etc. as some other pod(s)). + properties: + preferredDuringSchedulingIgnoredDuringExecution: + description: The scheduler will prefer to schedule + pods to nodes that satisfy the anti-affinity expressions + specified by this field, but it may choose a node + that violates one or more of the expressions. The + node that is most preferred is the one with the + greatest sum of weights, i.e. for each node that + meets all of the scheduling requirements (resource + request, requiredDuringScheduling anti-affinity + expressions, etc.), compute a sum by iterating through + the elements of this field and adding "weight" to + the sum if the node has pods which matches the corresponding + podAffinityTerm; the node(s) with the highest sum + are the most preferred. + items: + description: The weights of all of the matched WeightedPodAffinityTerm + fields are added per-node to find the most preferred + node(s) + properties: + podAffinityTerm: + description: Required. A pod affinity term, + associated with the corresponding weight. + properties: + labelSelector: + description: A label query over a set of + resources, in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list + of label selector requirements. The + requirements are ANDed. + items: + description: A label selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: key is the label + key that the selector applies + to. + type: string + operator: + description: operator represents + a key's relationship to a set + of values. Valid operators are + In, NotIn, Exists and DoesNotExist. + type: string + values: + description: values is an array + of string values. If the operator + is In or NotIn, the values array + must be non-empty. If the operator + is Exists or DoesNotExist, the + values array must be empty. + This array is replaced during + a strategic merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of + {key,value} pairs. A single {key,value} + in the matchLabels map is equivalent + to an element of matchExpressions, + whose key field is "key", the operator + is "In", and the values array contains + only "value". The requirements are + ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which + namespaces the labelSelector applies to + (matches against); null or empty list + means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located + (affinity) or not co-located (anti-affinity) + with the pods matching the labelSelector + in the specified namespaces, where co-located + is defined as running on a node whose + value of the label with key topologyKey + matches that of any node on which any + of the selected pods is running. Empty + topologyKey is not allowed. + type: string + required: + - topologyKey + type: object + weight: + description: weight associated with matching + the corresponding podAffinityTerm, in the + range 1-100. + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + requiredDuringSchedulingIgnoredDuringExecution: + description: If the anti-affinity requirements specified + by this field are not met at scheduling time, the + pod will not be scheduled onto the node. If the + anti-affinity requirements specified by this field + cease to be met at some point during pod execution + (e.g. due to a pod label update), the system may + or may not try to eventually evict the pod from + its node. When there are multiple elements, the + lists of nodes corresponding to each podAffinityTerm + are intersected, i.e. all terms must be satisfied. + items: + description: Defines a set of pods (namely those + matching the labelSelector relative to the given + namespace(s)) that this pod should be co-located + (affinity) or not co-located (anti-affinity) with, + where co-located is defined as running on a node + whose value of the label with key + matches that of any node on which a pod of the + set of pods is running + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list + of label selector requirements. The requirements + are ANDed. + items: + description: A label selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: key is the label key + that the selector applies to. + type: string + operator: + description: operator represents a + key's relationship to a set of values. + Valid operators are In, NotIn, Exists + and DoesNotExist. + type: string + values: + description: values is an array of + string values. If the operator is + In or NotIn, the values array must + be non-empty. If the operator is + Exists or DoesNotExist, the values + array must be empty. This array + is replaced during a strategic merge + patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator + is "In", and the values array contains + only "value". The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located (affinity) + or not co-located (anti-affinity) with the + pods matching the labelSelector in the specified + namespaces, where co-located is defined as + running on a node whose value of the label + with key topologyKey matches that of any node + on which any of the selected pods is running. + Empty topologyKey is not allowed. + type: string + required: + - topologyKey + type: object + type: array + type: object + type: object + branch: + properties: + else: + type: string + elseFail: + properties: + failed_node_id: + description: The node id that threw the error. + type: string + message: + description: Error message thrown. + type: string + type: object + elseIf: + items: + properties: + condition: + type: object + then: + type: string + required: + - condition + - then + type: object + type: array + x-kubernetes-list-type: atomic + if: + properties: + condition: + type: object + then: + type: string + required: + - condition + - then + type: object + required: + - if + type: object + config: + description: ConfigMap holds configuration data for pods to + consume. + properties: + apiVersion: + description: 'APIVersion defines the versioned schema + of this representation of an object. Servers should + convert recognized schemas to the latest internal value, + and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + type: string + binaryData: + additionalProperties: + format: byte + type: string + description: BinaryData contains the binary data. Each + key must consist of alphanumeric characters, '-', '_' + or '.'. BinaryData can contain byte sequences that are + not in the UTF-8 range. The keys stored in BinaryData + must not overlap with the ones in the Data field, this + is enforced during validation process. Using this field + will require 1.10+ apiserver and kubelet. + type: object + data: + additionalProperties: + type: string + description: Data contains the configuration data. Each + key must consist of alphanumeric characters, '-', '_' + or '.'. Values with non-UTF-8 byte sequences must use + the BinaryData field. The keys stored in Data must not + overlap with the keys in the BinaryData field, this + is enforced during validation process. + type: object + immutable: + description: Immutable, if set to true, ensures that data + stored in the ConfigMap cannot be updated (only object + metadata can be modified). If not set to true, the field + can be modified at any time. Defaulted to nil. This + is a beta field enabled by ImmutableEphemeralVolumes + feature gate. + type: boolean + kind: + description: 'Kind is a string value representing the + REST resource this object represents. Servers may infer + this from the endpoint the client submits requests to. + Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + type: string + metadata: + description: 'Standard object''s metadata. More info: + https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata' + properties: + annotations: + additionalProperties: + type: string + type: object + finalizers: + items: + type: string + type: array + labels: + additionalProperties: + type: string + type: object + name: + type: string + namespace: + type: string + type: object + type: object + executionDeadline: + description: Node execution timeout + type: string + hostname: + description: Specifies the hostname of the Pod If not specified, + the pod's hostname will be set to a system-defined value. + type: string + id: + type: string + imagePullSecrets: + description: 'ImagePullSecrets is an optional list of references + to secrets in the same namespace to use for pulling any + of the images used by this PodSpec. If specified, these + secrets will be passed to individual puller implementations + for them to use. For example, in the case of docker, only + DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod' + items: + description: LocalObjectReference contains enough information + to let you locate the referenced object inside the same + namespace. + properties: + name: + description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names + TODO: Add other useful fields. apiVersion, kind, uid?' + type: string + type: object + type: array + x-kubernetes-list-type: atomic + inputBindings: + items: + type: object + type: array + x-kubernetes-list-type: atomic + interruptible: + description: The value set to True means task is OK with getting + interrupted + type: boolean + kind: + description: NodeKind refers to the type of Node. + type: string + name: + type: string + outputAlias: + items: + properties: + alias: + description: A workflow-level unique alias that downstream + nodes can refer to in their input. + type: string + var: + description: Must match one of the output variable names + on a node. + type: string + type: object + type: array + x-kubernetes-list-type: atomic + resources: + description: ResourceRequirements describes the compute resource + requirements. + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + description: 'Limits describes the maximum amount of compute + resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/' + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + description: 'Requests describes the minimum amount of + compute resources required. If Requests is omitted for + a container, it defaults to Limits if that is explicitly + specified, otherwise to an implementation-defined value. + More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/' + type: object + type: object + retry: + description: Strategy to be used to Retry a node that is in + RetryableFailure state + properties: + minAttempts: + description: MinAttempts implies the atleast n attempts + to try this node before giving up. The atleast here + is because we may fail to write the attempt information + and end up retrying again. Also `0` and `1` both mean + atleast one attempt will be done. 0 is a degenerate + case. + type: integer + required: + - minAttempts + type: object + schedulerName: + description: If specified, the pod will be dispatched by specified + scheduler. If not specified, the pod will be dispatched + by default scheduler. + type: string + securityContext: + description: 'SecurityContext holds pod-level security attributes + and common container settings. Optional: Defaults to empty. See + type description for default values of each field.' + properties: + fsGroup: + description: "A special supplemental group that applies + to all containers in a pod. Some volume types allow + the Kubelet to change the ownership of that volume to + be owned by the pod: \n 1. The owning GID will be the + FSGroup 2. The setgid bit is set (new files created + in the volume will be owned by FSGroup) 3. The permission + bits are OR'd with rw-rw---- \n If unset, the Kubelet + will not modify the ownership and permissions of any + volume." + format: int64 + type: integer + fsGroupChangePolicy: + description: 'fsGroupChangePolicy defines behavior of + changing ownership and permission of the volume before + being exposed inside Pod. This field will only apply + to volume types which support fsGroup based ownership(and + permissions). It will have no effect on ephemeral volume + types such as: secret, configmaps and emptydir. Valid + values are "OnRootMismatch" and "Always". If not specified, + "Always" is used.' + type: string + runAsGroup: + description: The GID to run the entrypoint of the container + process. Uses runtime default if unset. May also be + set in SecurityContext. If set in both SecurityContext + and PodSecurityContext, the value specified in SecurityContext + takes precedence for that container. + format: int64 + type: integer + runAsNonRoot: + description: Indicates that the container must run as + a non-root user. If true, the Kubelet will validate + the image at runtime to ensure that it does not run + as UID 0 (root) and fail to start the container if it + does. If unset or false, no such validation will be + performed. May also be set in SecurityContext. If set + in both SecurityContext and PodSecurityContext, the + value specified in SecurityContext takes precedence. + type: boolean + runAsUser: + description: The UID to run the entrypoint of the container + process. Defaults to user specified in image metadata + if unspecified. May also be set in SecurityContext. If + set in both SecurityContext and PodSecurityContext, + the value specified in SecurityContext takes precedence + for that container. + format: int64 + type: integer + seLinuxOptions: + description: The SELinux context to be applied to all + containers. If unspecified, the container runtime will + allocate a random SELinux context for each container. May + also be set in SecurityContext. If set in both SecurityContext + and PodSecurityContext, the value specified in SecurityContext + takes precedence for that container. + properties: + level: + description: Level is SELinux level label that applies + to the container. + type: string + role: + description: Role is a SELinux role label that applies + to the container. + type: string + type: + description: Type is a SELinux type label that applies + to the container. + type: string + user: + description: User is a SELinux user label that applies + to the container. + type: string + type: object + seccompProfile: + description: The seccomp options to use by the containers + in this pod. + properties: + localhostProfile: + description: localhostProfile indicates a profile + defined in a file on the node should be used. The + profile must be preconfigured on the node to work. + Must be a descending path, relative to the kubelet's + configured seccomp profile location. Must only be + set if type is "Localhost". + type: string + type: + description: "type indicates which kind of seccomp + profile will be applied. Valid options are: \n Localhost + - a profile defined in a file on the node should + be used. RuntimeDefault - the container runtime + default profile should be used. Unconfined - no + profile should be applied." + type: string + required: + - type + type: object + supplementalGroups: + description: A list of groups applied to the first process + run in each container, in addition to the container's + primary GID. If unspecified, no groups will be added + to any container. + items: + format: int64 + type: integer + type: array + sysctls: + description: Sysctls hold a list of namespaced sysctls + used for the pod. Pods with unsupported sysctls (by + the container runtime) might fail to launch. + items: + description: Sysctl defines a kernel parameter to be + set + properties: + name: + description: Name of a property to set + type: string + value: + description: Value of a property to set + type: string + required: + - name + - value + type: object + type: array + windowsOptions: + description: The Windows specific settings applied to + all containers. If unspecified, the options within a + container's SecurityContext will be used. If set in + both SecurityContext and PodSecurityContext, the value + specified in SecurityContext takes precedence. + properties: + gmsaCredentialSpec: + description: GMSACredentialSpec is where the GMSA + admission webhook (https://github.com/kubernetes-sigs/windows-gmsa) + inlines the contents of the GMSA credential spec + named by the GMSACredentialSpecName field. + type: string + gmsaCredentialSpecName: + description: GMSACredentialSpecName is the name of + the GMSA credential spec to use. + type: string + runAsUserName: + description: The UserName in Windows to run the entrypoint + of the container process. Defaults to the user specified + in image metadata if unspecified. May also be set + in PodSecurityContext. If set in both SecurityContext + and PodSecurityContext, the value specified in SecurityContext + takes precedence. + type: string + type: object + type: object + subdomain: + description: If specified, the fully qualified Pod hostname + will be "...svc.". If not specified, the pod will not have a domainname + at all. + type: string + task: + type: string + tolerations: + description: If specified, the pod's tolerations. + items: + description: The pod this Toleration is attached to tolerates + any taint that matches the triple using + the matching operator . + properties: + effect: + description: Effect indicates the taint effect to match. + Empty means match all taint effects. When specified, + allowed values are NoSchedule, PreferNoSchedule and + NoExecute. + type: string + key: + description: Key is the taint key that the toleration + applies to. Empty means match all taint keys. If the + key is empty, operator must be Exists; this combination + means to match all values and all keys. + type: string + operator: + description: Operator represents a key's relationship + to the value. Valid operators are Exists and Equal. + Defaults to Equal. Exists is equivalent to wildcard + for value, so that a pod can tolerate all taints of + a particular category. + type: string + tolerationSeconds: + description: TolerationSeconds represents the period + of time the toleration (which must be of effect NoExecute, + otherwise this field is ignored) tolerates the taint. + By default, it is not set, which means tolerate the + taint forever (do not evict). Zero and negative values + will be treated as 0 (evict immediately) by the system. + format: int64 + type: integer + value: + description: Value is the taint value the toleration + matches to. If the operator is Exists, the value should + be empty, otherwise just a regular string. + type: string + type: object + type: array + x-kubernetes-list-type: atomic + workflow: + properties: + launchPlanRefId: + description: Either one of the two + properties: + domain: + description: Name of the domain the resource belongs + to. A domain can be considered as a subset within + a specific project. + type: string + name: + description: User provided value for the resource. + type: string + project: + description: Name of the project the resource belongs + to. + type: string + resource_type: + description: Identifies the specific type of resource + that this identifier corresponds to. + format: int32 + type: integer + version: + description: Specific version of the resource. + type: string + type: object + subWorkflowRef: + description: 'We currently want the SubWorkflow to be + completely contained in the node. this is because We + use the node status to store the information of the + execution. Important Note: This may cause a bloat in + case we use the same SubWorkflow in multiple nodes. + The recommended technique for that is to use launch + plan refs. This is because we will end up executing + the launch plan refs as disparate executions in Flyte + propeller. This is potentially better as it prevents + us from hitting the storage limit in etcd Workflow *WorkflowSpec + `json:"workflow,omitempty"`' + type: string + type: object + required: + - id + - kind + type: object + type: object + onFailure: + description: Defines a single node to execute in case the system + determined the Workflow has failed. + properties: + activeDeadline: + description: StartTime before the system will actively try to + mark it failed and kill associated containers. Value must + be a positive integer. This includes time spent waiting in + the queue. + type: string + affinity: + description: If specified, the pod's scheduling constraints + properties: + nodeAffinity: + description: Describes node affinity scheduling rules for + the pod. + properties: + preferredDuringSchedulingIgnoredDuringExecution: + description: The scheduler will prefer to schedule pods + to nodes that satisfy the affinity expressions specified + by this field, but it may choose a node that violates + one or more of the expressions. The node that is most + preferred is the one with the greatest sum of weights, + i.e. for each node that meets all of the scheduling + requirements (resource request, requiredDuringScheduling + affinity expressions, etc.), compute a sum by iterating + through the elements of this field and adding "weight" + to the sum if the node matches the corresponding matchExpressions; + the node(s) with the highest sum are the most preferred. + items: + description: An empty preferred scheduling term matches + all objects with implicit weight 0 (i.e. it's a + no-op). A null preferred scheduling term matches + no objects (i.e. is also a no-op). + properties: + preference: + description: A node selector term, associated + with the corresponding weight. + properties: + matchExpressions: + description: A list of node selector requirements + by node's labels. + items: + description: A node selector requirement + is a selector that contains values, a + key, and an operator that relates the + key and values. + properties: + key: + description: The label key that the + selector applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, the + values array must be non-empty. If + the operator is Exists or DoesNotExist, + the values array must be empty. If + the operator is Gt or Lt, the values + array must have a single element, + which will be interpreted as an integer. + This array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchFields: + description: A list of node selector requirements + by node's fields. + items: + description: A node selector requirement + is a selector that contains values, a + key, and an operator that relates the + key and values. + properties: + key: + description: The label key that the + selector applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, the + values array must be non-empty. If + the operator is Exists or DoesNotExist, + the values array must be empty. If + the operator is Gt or Lt, the values + array must have a single element, + which will be interpreted as an integer. + This array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + type: object + weight: + description: Weight associated with matching the + corresponding nodeSelectorTerm, in the range + 1-100. + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + requiredDuringSchedulingIgnoredDuringExecution: + description: If the affinity requirements specified + by this field are not met at scheduling time, the + pod will not be scheduled onto the node. If the affinity + requirements specified by this field cease to be met + at some point during pod execution (e.g. due to an + update), the system may or may not try to eventually + evict the pod from its node. + properties: + nodeSelectorTerms: + description: Required. A list of node selector terms. + The terms are ORed. + items: + description: A null or empty node selector term + matches no objects. The requirements of them + are ANDed. The TopologySelectorTerm type implements + a subset of the NodeSelectorTerm. + properties: + matchExpressions: + description: A list of node selector requirements + by node's labels. + items: + description: A node selector requirement + is a selector that contains values, a + key, and an operator that relates the + key and values. + properties: + key: + description: The label key that the + selector applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, the + values array must be non-empty. If + the operator is Exists or DoesNotExist, + the values array must be empty. If + the operator is Gt or Lt, the values + array must have a single element, + which will be interpreted as an integer. + This array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchFields: + description: A list of node selector requirements + by node's fields. + items: + description: A node selector requirement + is a selector that contains values, a + key, and an operator that relates the + key and values. + properties: + key: + description: The label key that the + selector applies to. + type: string + operator: + description: Represents a key's relationship + to a set of values. Valid operators + are In, NotIn, Exists, DoesNotExist. + Gt, and Lt. + type: string + values: + description: An array of string values. + If the operator is In or NotIn, the + values array must be non-empty. If + the operator is Exists or DoesNotExist, + the values array must be empty. If + the operator is Gt or Lt, the values + array must have a single element, + which will be interpreted as an integer. + This array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + type: object + type: array + required: + - nodeSelectorTerms + type: object + type: object + podAffinity: + description: Describes pod affinity scheduling rules (e.g. + co-locate this pod in the same node, zone, etc. as some + other pod(s)). + properties: + preferredDuringSchedulingIgnoredDuringExecution: + description: The scheduler will prefer to schedule pods + to nodes that satisfy the affinity expressions specified + by this field, but it may choose a node that violates + one or more of the expressions. The node that is most + preferred is the one with the greatest sum of weights, + i.e. for each node that meets all of the scheduling + requirements (resource request, requiredDuringScheduling + affinity expressions, etc.), compute a sum by iterating + through the elements of this field and adding "weight" + to the sum if the node has pods which matches the + corresponding podAffinityTerm; the node(s) with the + highest sum are the most preferred. + items: + description: The weights of all of the matched WeightedPodAffinityTerm + fields are added per-node to find the most preferred + node(s) + properties: + podAffinityTerm: + description: Required. A pod affinity term, associated + with the corresponding weight. + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list + of label selector requirements. The + requirements are ANDed. + items: + description: A label selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: key is the label key + that the selector applies to. + type: string + operator: + description: operator represents + a key's relationship to a set + of values. Valid operators are + In, NotIn, Exists and DoesNotExist. + type: string + values: + description: values is an array + of string values. If the operator + is In or NotIn, the values array + must be non-empty. If the operator + is Exists or DoesNotExist, the + values array must be empty. This + array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator + is "In", and the values array contains + only "value". The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located + (affinity) or not co-located (anti-affinity) + with the pods matching the labelSelector + in the specified namespaces, where co-located + is defined as running on a node whose value + of the label with key topologyKey matches + that of any node on which any of the selected + pods is running. Empty topologyKey is not + allowed. + type: string + required: + - topologyKey + type: object + weight: + description: weight associated with matching the + corresponding podAffinityTerm, in the range + 1-100. + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + requiredDuringSchedulingIgnoredDuringExecution: + description: If the affinity requirements specified + by this field are not met at scheduling time, the + pod will not be scheduled onto the node. If the affinity + requirements specified by this field cease to be met + at some point during pod execution (e.g. due to a + pod label update), the system may or may not try to + eventually evict the pod from its node. When there + are multiple elements, the lists of nodes corresponding + to each podAffinityTerm are intersected, i.e. all + terms must be satisfied. + items: + description: Defines a set of pods (namely those matching + the labelSelector relative to the given namespace(s)) + that this pod should be co-located (affinity) or + not co-located (anti-affinity) with, where co-located + is defined as running on a node whose value of the + label with key matches that of any + node on which a pod of the set of pods is running + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list of + label selector requirements. The requirements + are ANDed. + items: + description: A label selector requirement + is a selector that contains values, a + key, and an operator that relates the + key and values. + properties: + key: + description: key is the label key that + the selector applies to. + type: string + operator: + description: operator represents a key's + relationship to a set of values. Valid + operators are In, NotIn, Exists and + DoesNotExist. + type: string + values: + description: values is an array of string + values. If the operator is In or NotIn, + the values array must be non-empty. + If the operator is Exists or DoesNotExist, + the values array must be empty. This + array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator is + "In", and the values array contains only + "value". The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located (affinity) + or not co-located (anti-affinity) with the pods + matching the labelSelector in the specified + namespaces, where co-located is defined as running + on a node whose value of the label with key + topologyKey matches that of any node on which + any of the selected pods is running. Empty topologyKey + is not allowed. + type: string + required: + - topologyKey + type: object + type: array + type: object + podAntiAffinity: + description: Describes pod anti-affinity scheduling rules + (e.g. avoid putting this pod in the same node, zone, etc. + as some other pod(s)). + properties: + preferredDuringSchedulingIgnoredDuringExecution: + description: The scheduler will prefer to schedule pods + to nodes that satisfy the anti-affinity expressions + specified by this field, but it may choose a node + that violates one or more of the expressions. The + node that is most preferred is the one with the greatest + sum of weights, i.e. for each node that meets all + of the scheduling requirements (resource request, + requiredDuringScheduling anti-affinity expressions, + etc.), compute a sum by iterating through the elements + of this field and adding "weight" to the sum if the + node has pods which matches the corresponding podAffinityTerm; + the node(s) with the highest sum are the most preferred. + items: + description: The weights of all of the matched WeightedPodAffinityTerm + fields are added per-node to find the most preferred + node(s) + properties: + podAffinityTerm: + description: Required. A pod affinity term, associated + with the corresponding weight. + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list + of label selector requirements. The + requirements are ANDed. + items: + description: A label selector requirement + is a selector that contains values, + a key, and an operator that relates + the key and values. + properties: + key: + description: key is the label key + that the selector applies to. + type: string + operator: + description: operator represents + a key's relationship to a set + of values. Valid operators are + In, NotIn, Exists and DoesNotExist. + type: string + values: + description: values is an array + of string values. If the operator + is In or NotIn, the values array + must be non-empty. If the operator + is Exists or DoesNotExist, the + values array must be empty. This + array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator + is "In", and the values array contains + only "value". The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located + (affinity) or not co-located (anti-affinity) + with the pods matching the labelSelector + in the specified namespaces, where co-located + is defined as running on a node whose value + of the label with key topologyKey matches + that of any node on which any of the selected + pods is running. Empty topologyKey is not + allowed. + type: string + required: + - topologyKey + type: object + weight: + description: weight associated with matching the + corresponding podAffinityTerm, in the range + 1-100. + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + requiredDuringSchedulingIgnoredDuringExecution: + description: If the anti-affinity requirements specified + by this field are not met at scheduling time, the + pod will not be scheduled onto the node. If the anti-affinity + requirements specified by this field cease to be met + at some point during pod execution (e.g. due to a + pod label update), the system may or may not try to + eventually evict the pod from its node. When there + are multiple elements, the lists of nodes corresponding + to each podAffinityTerm are intersected, i.e. all + terms must be satisfied. + items: + description: Defines a set of pods (namely those matching + the labelSelector relative to the given namespace(s)) + that this pod should be co-located (affinity) or + not co-located (anti-affinity) with, where co-located + is defined as running on a node whose value of the + label with key matches that of any + node on which a pod of the set of pods is running + properties: + labelSelector: + description: A label query over a set of resources, + in this case pods. + properties: + matchExpressions: + description: matchExpressions is a list of + label selector requirements. The requirements + are ANDed. + items: + description: A label selector requirement + is a selector that contains values, a + key, and an operator that relates the + key and values. + properties: + key: + description: key is the label key that + the selector applies to. + type: string + operator: + description: operator represents a key's + relationship to a set of values. Valid + operators are In, NotIn, Exists and + DoesNotExist. + type: string + values: + description: values is an array of string + values. If the operator is In or NotIn, + the values array must be non-empty. + If the operator is Exists or DoesNotExist, + the values array must be empty. This + array is replaced during a strategic + merge patch. + items: + type: string + type: array + required: + - key + - operator + type: object + type: array + matchLabels: + additionalProperties: + type: string + description: matchLabels is a map of {key,value} + pairs. A single {key,value} in the matchLabels + map is equivalent to an element of matchExpressions, + whose key field is "key", the operator is + "In", and the values array contains only + "value". The requirements are ANDed. + type: object + type: object + namespaces: + description: namespaces specifies which namespaces + the labelSelector applies to (matches against); + null or empty list means "this pod's namespace" + items: + type: string + type: array + topologyKey: + description: This pod should be co-located (affinity) + or not co-located (anti-affinity) with the pods + matching the labelSelector in the specified + namespaces, where co-located is defined as running + on a node whose value of the label with key + topologyKey matches that of any node on which + any of the selected pods is running. Empty topologyKey + is not allowed. + type: string + required: + - topologyKey + type: object + type: array + type: object + type: object + branch: + properties: + else: + type: string + elseFail: + properties: + failed_node_id: + description: The node id that threw the error. + type: string + message: + description: Error message thrown. + type: string + type: object + elseIf: + items: + properties: + condition: + type: object + then: + type: string + required: + - condition + - then + type: object + type: array + x-kubernetes-list-type: atomic + if: + properties: + condition: + type: object + then: + type: string + required: + - condition + - then + type: object + required: + - if + type: object + config: + description: ConfigMap holds configuration data for pods to + consume. + properties: + apiVersion: + description: 'APIVersion defines the versioned schema of + this representation of an object. Servers should convert + recognized schemas to the latest internal value, and may + reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + type: string + binaryData: + additionalProperties: + format: byte + type: string + description: BinaryData contains the binary data. Each key + must consist of alphanumeric characters, '-', '_' or '.'. + BinaryData can contain byte sequences that are not in + the UTF-8 range. The keys stored in BinaryData must not + overlap with the ones in the Data field, this is enforced + during validation process. Using this field will require + 1.10+ apiserver and kubelet. + type: object + data: + additionalProperties: + type: string + description: Data contains the configuration data. Each + key must consist of alphanumeric characters, '-', '_' + or '.'. Values with non-UTF-8 byte sequences must use + the BinaryData field. The keys stored in Data must not + overlap with the keys in the BinaryData field, this is + enforced during validation process. + type: object + immutable: + description: Immutable, if set to true, ensures that data + stored in the ConfigMap cannot be updated (only object + metadata can be modified). If not set to true, the field + can be modified at any time. Defaulted to nil. This is + a beta field enabled by ImmutableEphemeralVolumes feature + gate. + type: boolean + kind: + description: 'Kind is a string value representing the REST + resource this object represents. Servers may infer this + from the endpoint the client submits requests to. Cannot + be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + type: string + metadata: + description: 'Standard object''s metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata' + properties: + annotations: + additionalProperties: + type: string + type: object + finalizers: + items: + type: string + type: array + labels: + additionalProperties: + type: string + type: object + name: + type: string + namespace: + type: string + type: object + type: object + executionDeadline: + description: Node execution timeout + type: string + hostname: + description: Specifies the hostname of the Pod If not specified, + the pod's hostname will be set to a system-defined value. + type: string + id: + type: string + imagePullSecrets: + description: 'ImagePullSecrets is an optional list of references + to secrets in the same namespace to use for pulling any of + the images used by this PodSpec. If specified, these secrets + will be passed to individual puller implementations for them + to use. For example, in the case of docker, only DockerConfig + type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod' + items: + description: LocalObjectReference contains enough information + to let you locate the referenced object inside the same + namespace. + properties: + name: + description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names + TODO: Add other useful fields. apiVersion, kind, uid?' + type: string + type: object + type: array + x-kubernetes-list-type: atomic + inputBindings: + items: + type: object + type: array + x-kubernetes-list-type: atomic + interruptible: + description: The value set to True means task is OK with getting + interrupted + type: boolean + kind: + description: NodeKind refers to the type of Node. + type: string + name: + type: string + outputAlias: + items: + properties: + alias: + description: A workflow-level unique alias that downstream + nodes can refer to in their input. + type: string + var: + description: Must match one of the output variable names + on a node. + type: string + type: object + type: array + x-kubernetes-list-type: atomic + resources: + description: ResourceRequirements describes the compute resource + requirements. + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + description: 'Limits describes the maximum amount of compute + resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/' + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + description: 'Requests describes the minimum amount of compute + resources required. If Requests is omitted for a container, + it defaults to Limits if that is explicitly specified, + otherwise to an implementation-defined value. More info: + https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/' + type: object + type: object + retry: + description: Strategy to be used to Retry a node that is in + RetryableFailure state + properties: + minAttempts: + description: MinAttempts implies the atleast n attempts + to try this node before giving up. The atleast here is + because we may fail to write the attempt information and + end up retrying again. Also `0` and `1` both mean atleast + one attempt will be done. 0 is a degenerate case. + type: integer + required: + - minAttempts + type: object + schedulerName: + description: If specified, the pod will be dispatched by specified + scheduler. If not specified, the pod will be dispatched by + default scheduler. + type: string + securityContext: + description: 'SecurityContext holds pod-level security attributes + and common container settings. Optional: Defaults to empty. See + type description for default values of each field.' + properties: + fsGroup: + description: "A special supplemental group that applies + to all containers in a pod. Some volume types allow the + Kubelet to change the ownership of that volume to be owned + by the pod: \n 1. The owning GID will be the FSGroup 2. + The setgid bit is set (new files created in the volume + will be owned by FSGroup) 3. The permission bits are OR'd + with rw-rw---- \n If unset, the Kubelet will not modify + the ownership and permissions of any volume." + format: int64 + type: integer + fsGroupChangePolicy: + description: 'fsGroupChangePolicy defines behavior of changing + ownership and permission of the volume before being exposed + inside Pod. This field will only apply to volume types + which support fsGroup based ownership(and permissions). + It will have no effect on ephemeral volume types such + as: secret, configmaps and emptydir. Valid values are + "OnRootMismatch" and "Always". If not specified, "Always" + is used.' + type: string + runAsGroup: + description: The GID to run the entrypoint of the container + process. Uses runtime default if unset. May also be set + in SecurityContext. If set in both SecurityContext and + PodSecurityContext, the value specified in SecurityContext + takes precedence for that container. + format: int64 + type: integer + runAsNonRoot: + description: Indicates that the container must run as a + non-root user. If true, the Kubelet will validate the + image at runtime to ensure that it does not run as UID + 0 (root) and fail to start the container if it does. If + unset or false, no such validation will be performed. + May also be set in SecurityContext. If set in both SecurityContext + and PodSecurityContext, the value specified in SecurityContext + takes precedence. + type: boolean + runAsUser: + description: The UID to run the entrypoint of the container + process. Defaults to user specified in image metadata + if unspecified. May also be set in SecurityContext. If + set in both SecurityContext and PodSecurityContext, the + value specified in SecurityContext takes precedence for + that container. + format: int64 + type: integer + seLinuxOptions: + description: The SELinux context to be applied to all containers. + If unspecified, the container runtime will allocate a + random SELinux context for each container. May also be + set in SecurityContext. If set in both SecurityContext + and PodSecurityContext, the value specified in SecurityContext + takes precedence for that container. + properties: + level: + description: Level is SELinux level label that applies + to the container. + type: string + role: + description: Role is a SELinux role label that applies + to the container. + type: string + type: + description: Type is a SELinux type label that applies + to the container. + type: string + user: + description: User is a SELinux user label that applies + to the container. + type: string + type: object + seccompProfile: + description: The seccomp options to use by the containers + in this pod. + properties: + localhostProfile: + description: localhostProfile indicates a profile defined + in a file on the node should be used. The profile + must be preconfigured on the node to work. Must be + a descending path, relative to the kubelet's configured + seccomp profile location. Must only be set if type + is "Localhost". + type: string + type: + description: "type indicates which kind of seccomp profile + will be applied. Valid options are: \n Localhost - + a profile defined in a file on the node should be + used. RuntimeDefault - the container runtime default + profile should be used. Unconfined - no profile should + be applied." + type: string + required: + - type + type: object + supplementalGroups: + description: A list of groups applied to the first process + run in each container, in addition to the container's + primary GID. If unspecified, no groups will be added + to any container. + items: + format: int64 + type: integer + type: array + sysctls: + description: Sysctls hold a list of namespaced sysctls used + for the pod. Pods with unsupported sysctls (by the container + runtime) might fail to launch. + items: + description: Sysctl defines a kernel parameter to be set + properties: + name: + description: Name of a property to set + type: string + value: + description: Value of a property to set + type: string + required: + - name + - value + type: object + type: array + windowsOptions: + description: The Windows specific settings applied to all + containers. If unspecified, the options within a container's + SecurityContext will be used. If set in both SecurityContext + and PodSecurityContext, the value specified in SecurityContext + takes precedence. + properties: + gmsaCredentialSpec: + description: GMSACredentialSpec is where the GMSA admission + webhook (https://github.com/kubernetes-sigs/windows-gmsa) + inlines the contents of the GMSA credential spec named + by the GMSACredentialSpecName field. + type: string + gmsaCredentialSpecName: + description: GMSACredentialSpecName is the name of the + GMSA credential spec to use. + type: string + runAsUserName: + description: The UserName in Windows to run the entrypoint + of the container process. Defaults to the user specified + in image metadata if unspecified. May also be set + in PodSecurityContext. If set in both SecurityContext + and PodSecurityContext, the value specified in SecurityContext + takes precedence. + type: string + type: object + type: object + subdomain: + description: If specified, the fully qualified Pod hostname + will be "...svc.". If not specified, the pod will not have a domainname + at all. + type: string + task: + type: string + tolerations: + description: If specified, the pod's tolerations. + items: + description: The pod this Toleration is attached to tolerates + any taint that matches the triple using + the matching operator . + properties: + effect: + description: Effect indicates the taint effect to match. + Empty means match all taint effects. When specified, + allowed values are NoSchedule, PreferNoSchedule and + NoExecute. + type: string + key: + description: Key is the taint key that the toleration + applies to. Empty means match all taint keys. If the + key is empty, operator must be Exists; this combination + means to match all values and all keys. + type: string + operator: + description: Operator represents a key's relationship + to the value. Valid operators are Exists and Equal. + Defaults to Equal. Exists is equivalent to wildcard + for value, so that a pod can tolerate all taints of + a particular category. + type: string + tolerationSeconds: + description: TolerationSeconds represents the period of + time the toleration (which must be of effect NoExecute, + otherwise this field is ignored) tolerates the taint. + By default, it is not set, which means tolerate the + taint forever (do not evict). Zero and negative values + will be treated as 0 (evict immediately) by the system. + format: int64 + type: integer + value: + description: Value is the taint value the toleration matches + to. If the operator is Exists, the value should be empty, + otherwise just a regular string. + type: string + type: object + type: array + x-kubernetes-list-type: atomic + workflow: + properties: + launchPlanRefId: + description: Either one of the two + properties: + domain: + description: Name of the domain the resource belongs + to. A domain can be considered as a subset within + a specific project. + type: string + name: + description: User provided value for the resource. + type: string + project: + description: Name of the project the resource belongs + to. + type: string + resource_type: + description: Identifies the specific type of resource + that this identifier corresponds to. + format: int32 + type: integer + version: + description: Specific version of the resource. + type: string + type: object + subWorkflowRef: + description: 'We currently want the SubWorkflow to be completely + contained in the node. this is because We use the node + status to store the information of the execution. Important + Note: This may cause a bloat in case we use the same SubWorkflow + in multiple nodes. The recommended technique for that + is to use launch plan refs. This is because we will end + up executing the launch plan refs as disparate executions + in Flyte propeller. This is potentially better as it prevents + us from hitting the storage limit in etcd Workflow *WorkflowSpec + `json:"workflow,omitempty"`' + type: string + type: object + required: + - id + - kind + type: object + onFailurePolicy: + description: Defines the policy for handling failures whether it's + to fail immediately, or let the nodes run to completion. + format: int32 + type: integer + outputBindings: + description: Defines the data links used to construct the final + outputs of the workflow. Bindings will typically refer to specific + outputs of a subset of the nodes executed in the Workflow. When + executing the end-node, the execution engine will traverse these + bindings and assemble the final set of outputs of the workflow. + items: + type: object + type: array + x-kubernetes-list-type: atomic + outputs: + description: Defines the declaration of the outputs types and names + this workflow is expected to generate. + type: object + required: + - connections + - edges + - id + - nodes + type: object + type: object + tasks: + additionalProperties: + type: object + type: object + workflowMeta: + properties: + eventVersion: + type: integer + type: object + required: + - executionId + - spec + - tasks + type: object + served: true + storage: true +status: + acceptedNames: + kind: "" + plural: "" + conditions: [] + storedVersions: [] diff --git a/pkg/apis/flyteworkflow/v1alpha1/branch.go b/pkg/apis/flyteworkflow/v1alpha1/branch.go index a8657805a..ea1e5a2c8 100644 --- a/pkg/apis/flyteworkflow/v1alpha1/branch.go +++ b/pkg/apis/flyteworkflow/v1alpha1/branch.go @@ -8,7 +8,7 @@ import ( ) type Error struct { - *core.Error + *core.Error `json:",inline"` } func (in Error) UnmarshalJSON(b []byte) error { @@ -36,6 +36,7 @@ func (in *Error) DeepCopyInto(out *Error) { } +// +kubebuilder:validation:Type=object type BooleanExpression struct { *core.BooleanExpression } @@ -78,7 +79,8 @@ func (in *IfBlock) GetThenNode() *NodeID { } type BranchNodeSpec struct { - If IfBlock `json:"if"` + If IfBlock `json:"if"` + // +listType=atomic ElseIf []*IfBlock `json:"elseIf,omitempty"` Else *NodeID `json:"else,omitempty"` ElseFail *Error `json:"elseFail,omitempty"` diff --git a/pkg/apis/flyteworkflow/v1alpha1/doc.go b/pkg/apis/flyteworkflow/v1alpha1/doc.go index 37762e696..59d111b4f 100644 --- a/pkg/apis/flyteworkflow/v1alpha1/doc.go +++ b/pkg/apis/flyteworkflow/v1alpha1/doc.go @@ -2,4 +2,5 @@ // Package v1alpha1 is the v1alpha1 version of the API. // +groupName=flyteworkflow.flyte.net +// +k8s:openapi-gen=true package v1alpha1 diff --git a/pkg/apis/flyteworkflow/v1alpha1/error.go b/pkg/apis/flyteworkflow/v1alpha1/error.go index 68ce9be13..b701e2d3c 100644 --- a/pkg/apis/flyteworkflow/v1alpha1/error.go +++ b/pkg/apis/flyteworkflow/v1alpha1/error.go @@ -9,7 +9,7 @@ import ( // Wrapper around core.Execution error. Execution Error has a protobuf enum and hence needs to be wrapped by custom marshaller type ExecutionError struct { - *core.ExecutionError + *core.ExecutionError `json:",inline"` } func (in *ExecutionError) UnmarshalJSON(b []byte) error { diff --git a/pkg/apis/flyteworkflow/v1alpha1/execution_config.go b/pkg/apis/flyteworkflow/v1alpha1/execution_config.go index 7a5830bf6..50c8805d0 100644 --- a/pkg/apis/flyteworkflow/v1alpha1/execution_config.go +++ b/pkg/apis/flyteworkflow/v1alpha1/execution_config.go @@ -10,7 +10,7 @@ import ( // handing off to plugins/tasks. Sharding behavior may change in the future. // Background available at https://github.com/flyteorg/flyte/issues/211 type RawOutputDataConfig struct { - *admin.RawOutputDataConfig + *admin.RawOutputDataConfig `json:",inline"` } func (in *RawOutputDataConfig) DeepCopyInto(out *RawOutputDataConfig) { @@ -20,35 +20,36 @@ func (in *RawOutputDataConfig) DeepCopyInto(out *RawOutputDataConfig) { // This contains workflow-execution specifications and overrides. type ExecutionConfig struct { // Maps individual task types to their alternate (non-default) plugin handlers by name. - TaskPluginImpls map[string]TaskPluginOverride + TaskPluginImpls map[string]TaskPluginOverride `json:"TaskPluginImpls"` // Can be used to control the number of parallel nodes to run within the workflow. This is useful to achieve fairness. - MaxParallelism uint32 + MaxParallelism uint32 `json:"MaxParallelism"` // Defines execution behavior for processing nodes. - RecoveryExecution WorkflowExecutionIdentifier + RecoveryExecution WorkflowExecutionIdentifier `json:"RecoveryExecution"` // Defines the resource requests and limits specified for tasks run as part of this execution that ought to be // applied at execution time. - TaskResources TaskResources + TaskResources TaskResources `json:"TaskResources"` } type TaskPluginOverride struct { - PluginIDs []string - MissingPluginBehavior admin.PluginOverride_MissingPluginBehavior + // +listType=atomic + PluginIDs []string `json:"PluginsIDs,omitempty"` + MissingPluginBehavior admin.PluginOverride_MissingPluginBehavior `json:"MissingPluginBehavior"` } // Defines a set of configurable resources of different types that a task can request or apply as limits. type TaskResourceSpec struct { - CPU resource.Quantity - Memory resource.Quantity - EphemeralStorage resource.Quantity - Storage resource.Quantity - GPU resource.Quantity + CPU resource.Quantity `json:"CPU"` + Memory resource.Quantity `json:"Memory"` + EphemeralStorage resource.Quantity `json:"EphemeralStorage"` + Storage resource.Quantity `json:"Storage"` + GPU resource.Quantity `json:"GPU"` } // Defines the complete closure of compute resources a task can request and apply as limits. type TaskResources struct { // If the node where a task is running has enough of a resource available, a // container may use more resources than its request for that resource specifies. - Requests TaskResourceSpec + Requests TaskResourceSpec `json:"Requests"` // A hard limit, a task cannot consume resources greater than the limit specifies. - Limits TaskResourceSpec + Limits TaskResourceSpec `json:"Limits"` } diff --git a/pkg/apis/flyteworkflow/v1alpha1/identifier.go b/pkg/apis/flyteworkflow/v1alpha1/identifier.go index 48c092f2c..e3b4a85a3 100644 --- a/pkg/apis/flyteworkflow/v1alpha1/identifier.go +++ b/pkg/apis/flyteworkflow/v1alpha1/identifier.go @@ -8,7 +8,7 @@ import ( ) type Identifier struct { - *core.Identifier + *core.Identifier `json:",inline"` } func (in *Identifier) UnmarshalJSON(b []byte) error { @@ -29,7 +29,7 @@ func (in *Identifier) DeepCopyInto(out *Identifier) { } type WorkflowExecutionIdentifier struct { - *core.WorkflowExecutionIdentifier + *core.WorkflowExecutionIdentifier `json:",inline"` } func (in *WorkflowExecutionIdentifier) DeepCopyInto(out *WorkflowExecutionIdentifier) { @@ -37,7 +37,7 @@ func (in *WorkflowExecutionIdentifier) DeepCopyInto(out *WorkflowExecutionIdenti } type TaskExecutionIdentifier struct { - *core.TaskExecutionIdentifier + *core.TaskExecutionIdentifier `json:",inline"` } func (in *TaskExecutionIdentifier) DeepCopyInto(out *TaskExecutionIdentifier) { diff --git a/pkg/apis/flyteworkflow/v1alpha1/node_status.go b/pkg/apis/flyteworkflow/v1alpha1/node_status.go index cc78b492a..c72954c36 100644 --- a/pkg/apis/flyteworkflow/v1alpha1/node_status.go +++ b/pkg/apis/flyteworkflow/v1alpha1/node_status.go @@ -35,7 +35,7 @@ func (in MutableStruct) IsDirty() bool { } type BranchNodeStatus struct { - MutableStruct + MutableStruct `json:"-"` Phase BranchNodePhase `json:"phase,omitempty"` FinalizedNodeID *NodeID `json:"finalNodeId,omitempty"` } @@ -95,10 +95,10 @@ const ( ) type DynamicNodeStatus struct { - MutableStruct - Phase DynamicNodePhase `json:"phase,omitempty"` - Reason string `json:"reason,omitempty"` - Error *ExecutionError `json:"error,omitempty"` + MutableStruct `json:"-"` + Phase DynamicNodePhase `json:"phase,omitempty"` + Reason string `json:"reason,omitempty"` + Error *ExecutionError `json:"error,omitempty"` } func (in *DynamicNodeStatus) GetDynamicNodePhase() DynamicNodePhase { @@ -157,7 +157,7 @@ const ( ) type WorkflowNodeStatus struct { - MutableStruct + MutableStruct `json:"-"` Phase WorkflowNodePhase `json:"phase,omitempty"` ExecutionError *core.ExecutionError `json:"executionError,omitempty"` } @@ -184,8 +184,9 @@ func (in *WorkflowNodeStatus) SetWorkflowNodePhase(phase WorkflowNodePhase) { } } +// +kubebuilder:validation:type=object type NodeStatus struct { - MutableStruct + MutableStruct `json:"-"` Phase NodePhase `json:"phase,omitempty"` QueuedAt *metav1.Time `json:"queuedAt,omitempty"` StartedAt *metav1.Time `json:"startedAt,omitempty"` @@ -710,7 +711,7 @@ func (in *CustomState) DeepCopy() *CustomState { } type TaskNodeStatus struct { - MutableStruct + MutableStruct `json:"-"` Phase int `json:"phase,omitempty"` PhaseVersion uint32 `json:"phaseVersion,omitempty"` PluginState []byte `json:"pState,omitempty"` diff --git a/pkg/apis/flyteworkflow/v1alpha1/nodes.go b/pkg/apis/flyteworkflow/v1alpha1/nodes.go index 94e8752d9..7f6112a20 100644 --- a/pkg/apis/flyteworkflow/v1alpha1/nodes.go +++ b/pkg/apis/flyteworkflow/v1alpha1/nodes.go @@ -12,6 +12,7 @@ import ( var marshaler = jsonpb.Marshaler{} +// +kubebuilder:validation:Type=object type OutputVarMap struct { *core.VariableMap } @@ -37,6 +38,7 @@ func (in *OutputVarMap) DeepCopyInto(out *OutputVarMap) { // Once we figure out the autogenerate story we can replace this } +// +kubebuilder:validation:Type=object type Binding struct { *core.Binding } @@ -72,7 +74,7 @@ type RetryStrategy struct { } type Alias struct { - core.Alias + core.Alias `json:",inline"` } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. @@ -83,7 +85,7 @@ func (in *Alias) DeepCopyInto(out *Alias) { } type NodeMetadata struct { - core.NodeMetadata + core.NodeMetadata `json:",inline"` } func (in *NodeMetadata) DeepCopyInto(out *NodeMetadata) { @@ -93,17 +95,19 @@ func (in *NodeMetadata) DeepCopyInto(out *NodeMetadata) { } type NodeSpec struct { - ID NodeID `json:"id"` - Name string `json:"name,omitempty"` - Resources *typesv1.ResourceRequirements `json:"resources,omitempty"` - Kind NodeKind `json:"kind"` - BranchNode *BranchNodeSpec `json:"branch,omitempty"` - TaskRef *TaskID `json:"task,omitempty"` - WorkflowNode *WorkflowNodeSpec `json:"workflow,omitempty"` - InputBindings []*Binding `json:"inputBindings,omitempty"` - Config *typesv1.ConfigMap `json:"config,omitempty"` - RetryStrategy *RetryStrategy `json:"retry,omitempty"` - OutputAliases []Alias `json:"outputAlias,omitempty"` + ID NodeID `json:"id"` + Name string `json:"name,omitempty"` + Resources *typesv1.ResourceRequirements `json:"resources,omitempty"` + Kind NodeKind `json:"kind"` + BranchNode *BranchNodeSpec `json:"branch,omitempty"` + TaskRef *TaskID `json:"task,omitempty"` + WorkflowNode *WorkflowNodeSpec `json:"workflow,omitempty"` + // +listType=atomic + InputBindings []*Binding `json:"inputBindings,omitempty"` + Config *typesv1.ConfigMap `json:"config,omitempty"` + RetryStrategy *RetryStrategy `json:"retry,omitempty"` + // +listType=atomic + OutputAliases []Alias `json:"outputAlias,omitempty"` // SecurityContext holds pod-level security attributes and common container settings. // Optional: Defaults to empty. See type description for default values of each field. @@ -116,6 +120,7 @@ type NodeSpec struct { // +optional // +patchMergeKey=name // +patchStrategy=merge + // +listType=atomic ImagePullSecrets []typesv1.LocalObjectReference `json:"imagePullSecrets,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,15,rep,name=imagePullSecrets"` // Specifies the hostname of the Pod // If not specified, the pod's hostname will be set to a system-defined value. @@ -134,6 +139,7 @@ type NodeSpec struct { SchedulerName string `json:"schedulerName,omitempty" protobuf:"bytes,19,opt,name=schedulerName"` // If specified, the pod's tolerations. // +optional + // +listType=atomic Tolerations []typesv1.Toleration `json:"tolerations,omitempty" protobuf:"bytes,22,opt,name=tolerations"` // Node execution timeout ExecutionDeadline *v1.Duration `json:"executionDeadline,omitempty"` diff --git a/pkg/apis/flyteworkflow/v1alpha1/openapi_generated.go b/pkg/apis/flyteworkflow/v1alpha1/openapi_generated.go new file mode 100644 index 000000000..102041670 --- /dev/null +++ b/pkg/apis/flyteworkflow/v1alpha1/openapi_generated.go @@ -0,0 +1,1487 @@ +//go:build !ignore_autogenerated +// +build !ignore_autogenerated + +// Code generated by openapi-gen. DO NOT EDIT. + +// This file was autogenerated by openapi-gen. Do not edit it manually! + +package v1alpha1 + +import ( + spec "github.com/go-openapi/spec" + common "k8s.io/kube-openapi/pkg/common" +) + +func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenAPIDefinition { + return map[string]common.OpenAPIDefinition{ + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Alias": schema_pkg_apis_flyteworkflow_v1alpha1_Alias(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Binding": schema_pkg_apis_flyteworkflow_v1alpha1_Binding(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.BooleanExpression": schema_pkg_apis_flyteworkflow_v1alpha1_BooleanExpression(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.BranchNodeSpec": schema_pkg_apis_flyteworkflow_v1alpha1_BranchNodeSpec(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.BranchNodeStatus": schema_pkg_apis_flyteworkflow_v1alpha1_BranchNodeStatus(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Connections": schema_pkg_apis_flyteworkflow_v1alpha1_Connections(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.DeprecatedConnections": schema_pkg_apis_flyteworkflow_v1alpha1_DeprecatedConnections(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.DynamicNodeStatus": schema_pkg_apis_flyteworkflow_v1alpha1_DynamicNodeStatus(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Error": schema_pkg_apis_flyteworkflow_v1alpha1_Error(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.ExecutionConfig": schema_pkg_apis_flyteworkflow_v1alpha1_ExecutionConfig(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.ExecutionError": schema_pkg_apis_flyteworkflow_v1alpha1_ExecutionError(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.FlyteWorkflow": schema_pkg_apis_flyteworkflow_v1alpha1_FlyteWorkflow(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.FlyteWorkflowList": schema_pkg_apis_flyteworkflow_v1alpha1_FlyteWorkflowList(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Identifier": schema_pkg_apis_flyteworkflow_v1alpha1_Identifier(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.IfBlock": schema_pkg_apis_flyteworkflow_v1alpha1_IfBlock(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Inputs": schema_pkg_apis_flyteworkflow_v1alpha1_Inputs(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.MutableStruct": schema_pkg_apis_flyteworkflow_v1alpha1_MutableStruct(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeDefaults": schema_pkg_apis_flyteworkflow_v1alpha1_NodeDefaults(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeMetadata": schema_pkg_apis_flyteworkflow_v1alpha1_NodeMetadata(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeSpec": schema_pkg_apis_flyteworkflow_v1alpha1_NodeSpec(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeStatus": schema_pkg_apis_flyteworkflow_v1alpha1_NodeStatus(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.OutputVarMap": schema_pkg_apis_flyteworkflow_v1alpha1_OutputVarMap(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.RawOutputDataConfig": schema_pkg_apis_flyteworkflow_v1alpha1_RawOutputDataConfig(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.RetryStrategy": schema_pkg_apis_flyteworkflow_v1alpha1_RetryStrategy(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskExecutionIdentifier": schema_pkg_apis_flyteworkflow_v1alpha1_TaskExecutionIdentifier(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskNodeStatus": schema_pkg_apis_flyteworkflow_v1alpha1_TaskNodeStatus(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskPluginOverride": schema_pkg_apis_flyteworkflow_v1alpha1_TaskPluginOverride(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskResourceSpec": schema_pkg_apis_flyteworkflow_v1alpha1_TaskResourceSpec(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskResources": schema_pkg_apis_flyteworkflow_v1alpha1_TaskResources(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskSpec": schema_pkg_apis_flyteworkflow_v1alpha1_TaskSpec(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowExecutionIdentifier": schema_pkg_apis_flyteworkflow_v1alpha1_WorkflowExecutionIdentifier(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowMeta": schema_pkg_apis_flyteworkflow_v1alpha1_WorkflowMeta(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowNodeSpec": schema_pkg_apis_flyteworkflow_v1alpha1_WorkflowNodeSpec(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowNodeStatus": schema_pkg_apis_flyteworkflow_v1alpha1_WorkflowNodeStatus(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowSpec": schema_pkg_apis_flyteworkflow_v1alpha1_WorkflowSpec(ref), + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowStatus": schema_pkg_apis_flyteworkflow_v1alpha1_WorkflowStatus(ref), + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_Alias(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "var": { + SchemaProps: spec.SchemaProps{ + Description: "Must match one of the output variable names on a node.", + Type: []string{"string"}, + Format: "", + }, + }, + "alias": { + SchemaProps: spec.SchemaProps{ + Description: "A workflow-level unique alias that downstream nodes can refer to in their input.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_Binding(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "Binding": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.Binding"), + }, + }, + }, + Required: []string{"Binding"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.Binding"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_BooleanExpression(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "BooleanExpression": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.BooleanExpression"), + }, + }, + }, + Required: []string{"BooleanExpression"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.BooleanExpression"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_BranchNodeSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "if": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.IfBlock"), + }, + }, + "elseIf": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.IfBlock"), + }, + }, + }, + }, + }, + "else": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "elseFail": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Error"), + }, + }, + }, + Required: []string{"if"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Error", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.IfBlock"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_BranchNodeStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "phase": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int32", + }, + }, + "finalNodeId": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"phase", "finalNodeId"}, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_Connections(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Connections keep track of downstream and upstream dependencies (including data and execution dependencies).", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "downstream": { + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + "upstream": { + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + }, + Required: []string{"downstream", "upstream"}, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_DeprecatedConnections(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Deprecated: Please use Connections instead", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "DownstreamEdges": { + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + "UpstreamEdges": { + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_DynamicNodeStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "phase": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int32", + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "error": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.ExecutionError"), + }, + }, + }, + Required: []string{"phase"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.ExecutionError"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_Error(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_ExecutionConfig(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "This contains workflow-execution specifications and overrides.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "TaskPluginImpls": { + SchemaProps: spec.SchemaProps{ + Description: "Maps individual task types to their alternate (non-default) plugin handlers by name.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskPluginOverride"), + }, + }, + }, + }, + }, + "MaxParallelism": { + SchemaProps: spec.SchemaProps{ + Description: "Can be used to control the number of parallel nodes to run within the workflow. This is useful to achieve fairness.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "RecoveryExecution": { + SchemaProps: spec.SchemaProps{ + Description: "Defines execution behavior for processing nodes.", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowExecutionIdentifier"), + }, + }, + "TaskResources": { + SchemaProps: spec.SchemaProps{ + Description: "Defines the resource requests and limits specified for tasks run as part of this execution that ought to be applied at execution time.", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskResources"), + }, + }, + }, + Required: []string{"TaskPluginImpls", "MaxParallelism", "RecoveryExecution", "TaskResources"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskPluginOverride", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskResources", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowExecutionIdentifier"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_ExecutionError(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Wrapper around core.Execution error. Execution Error has a protobuf enum and hence needs to be wrapped by custom marshaller", + Type: []string{"object"}, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_FlyteWorkflow(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FlyteWorkflow: represents one Execution Workflow object", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowSpec"), + }, + }, + "workflowMeta": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowMeta"), + }, + }, + "inputs": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Inputs"), + }, + }, + "executionId": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowExecutionIdentifier"), + }, + }, + "tasks": { + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskSpec"), + }, + }, + }, + }, + }, + "subWorkflows": { + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowSpec"), + }, + }, + }, + }, + }, + "activeDeadlineSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "node-defaults": { + SchemaProps: spec.SchemaProps{ + Description: "Defaults value of parameters to be used for nodes if not set by the node.", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeDefaults"), + }, + }, + "acceptedAt": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the time when the workflow has been accepted into the system.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + }, + }, + "serviceAccountName": { + SchemaProps: spec.SchemaProps{ + Description: "[DEPRECATED] ServiceAccountName is the name of the ServiceAccount to use to run this pod. [DEPRECATED] More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ [DEPRECATED] +optional", + Type: []string{"string"}, + Format: "", + }, + }, + "securityContext": { + SchemaProps: spec.SchemaProps{ + Description: "Security context fields to define privilege and access control settings", + Ref: ref("github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.SecurityContext"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Status is the only mutable section in the workflow. It holds all the execution information", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowStatus"), + }, + }, + "rawOutputDataConfig": { + SchemaProps: spec.SchemaProps{ + Description: "RawOutputDataConfig defines the configurations to use for generating raw outputs (e.g. blobs, schemas).", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.RawOutputDataConfig"), + }, + }, + "executionConfig": { + SchemaProps: spec.SchemaProps{ + Description: "Workflow-execution specifications and overrides", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.ExecutionConfig"), + }, + }, + }, + Required: []string{"spec", "executionId", "tasks"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.SecurityContext", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.ExecutionConfig", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Inputs", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeDefaults", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.RawOutputDataConfig", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskSpec", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowExecutionIdentifier", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowMeta", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowSpec", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_FlyteWorkflowList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FlyteWorkflowList is a list of FlyteWorkflow resources", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.FlyteWorkflow"), + }, + }, + }, + }, + }, + }, + Required: []string{"metadata", "items"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.FlyteWorkflow", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_Identifier(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_IfBlock(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "condition": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.BooleanExpression"), + }, + }, + "then": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"condition", "then"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.BooleanExpression"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_Inputs(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_MutableStruct(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "isDirty": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"isDirty"}, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_NodeDefaults(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "interruptible": { + SchemaProps: spec.SchemaProps{ + Description: "Default behaviour for Interruptible for nodes unless explicitly set at the node level.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_NodeMetadata(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "A friendly name for the Node", + Type: []string{"string"}, + Format: "", + }, + }, + "timeout": { + SchemaProps: spec.SchemaProps{ + Description: "The overall timeout of a task.", + Ref: ref("google.golang.org/protobuf/types/known/durationpb.Duration"), + }, + }, + "retries": { + SchemaProps: spec.SchemaProps{ + Description: "Number of retries per task.", + Ref: ref("github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.RetryStrategy"), + }, + }, + "InterruptibleValue": { + SchemaProps: spec.SchemaProps{ + Description: "Identify whether node is interruptible\n\nTypes that are valid to be assigned to InterruptibleValue:\n\t*NodeMetadata_Interruptible", + Ref: ref("github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.isNodeMetadata_InterruptibleValue"), + }, + }, + }, + Required: []string{"InterruptibleValue"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.RetryStrategy", "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.isNodeMetadata_InterruptibleValue", "google.golang.org/protobuf/types/known/durationpb.Duration"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_NodeSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "id": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "name": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "resources": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/api/core/v1.ResourceRequirements"), + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "branch": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.BranchNodeSpec"), + }, + }, + "task": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "workflow": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowNodeSpec"), + }, + }, + "inputBindings": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Binding"), + }, + }, + }, + }, + }, + "config": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/api/core/v1.ConfigMap"), + }, + }, + "retry": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.RetryStrategy"), + }, + }, + "outputAlias": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Alias"), + }, + }, + }, + }, + }, + "securityContext": { + SchemaProps: spec.SchemaProps{ + Description: "SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field.", + Ref: ref("k8s.io/api/core/v1.PodSecurityContext"), + }, + }, + "imagePullSecrets": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + }, + }, + }, + }, + }, + "hostname": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value.", + Type: []string{"string"}, + Format: "", + }, + }, + "subdomain": { + SchemaProps: spec.SchemaProps{ + Description: "If specified, the fully qualified Pod hostname will be \"...svc.\". If not specified, the pod will not have a domainname at all.", + Type: []string{"string"}, + Format: "", + }, + }, + "affinity": { + SchemaProps: spec.SchemaProps{ + Description: "If specified, the pod's scheduling constraints", + Ref: ref("k8s.io/api/core/v1.Affinity"), + }, + }, + "schedulerName": { + SchemaProps: spec.SchemaProps{ + Description: "If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler.", + Type: []string{"string"}, + Format: "", + }, + }, + "tolerations": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "If specified, the pod's tolerations.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/api/core/v1.Toleration"), + }, + }, + }, + }, + }, + "executionDeadline": { + SchemaProps: spec.SchemaProps{ + Description: "Node execution timeout", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "activeDeadline": { + SchemaProps: spec.SchemaProps{ + Description: "StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. This includes time spent waiting in the queue.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "interruptible": { + SchemaProps: spec.SchemaProps{ + Description: "The value set to True means task is OK with getting interrupted", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"id", "kind"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Alias", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Binding", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.BranchNodeSpec", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.RetryStrategy", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowNodeSpec", "k8s.io/api/core/v1.Affinity", "k8s.io/api/core/v1.ConfigMap", "k8s.io/api/core/v1.LocalObjectReference", "k8s.io/api/core/v1.PodSecurityContext", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.Toleration", "k8s.io/apimachinery/pkg/apis/meta/v1.Duration"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_NodeStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "phase": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int32", + }, + }, + "queuedAt": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + }, + }, + "startedAt": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + }, + }, + "stoppedAt": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + }, + }, + "lastUpdatedAt": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + }, + }, + "laStartedAt": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "attempts": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int64", + }, + }, + "systemFailures": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int64", + }, + }, + "cached": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, + "parentNode": { + SchemaProps: spec.SchemaProps{ + Description: "This is useful only for branch nodes. If this is set, then it can be used to determine if execution can proceed", + Type: []string{"string"}, + Format: "", + }, + }, + "branchStatus": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.BranchNodeStatus"), + }, + }, + "subNodeStatus": { + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeStatus"), + }, + }, + }, + }, + }, + "workflowNodeStatus": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowNodeStatus"), + }, + }, + "dynamicNodeStatus": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.DynamicNodeStatus"), + }, + }, + "error": { + SchemaProps: spec.SchemaProps{ + Description: "In case of Failing/Failed Phase, an execution error can be optionally associated with the Node", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.ExecutionError"), + }, + }, + }, + Required: []string{"phase"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.BranchNodeStatus", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.DynamicNodeStatus", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.ExecutionError", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeStatus", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.WorkflowNodeStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_OutputVarMap(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "VariableMap": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.VariableMap"), + }, + }, + }, + Required: []string{"VariableMap"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.VariableMap"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_RawOutputDataConfig(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "This contains an OutputLocationPrefix. When running against AWS, this should be something of the form s3://my-bucket, or s3://my-bucket/ A sharding string will automatically be appended to this prefix before handing off to plugins/tasks. Sharding behavior may change in the future. Background available at https://github.com/flyteorg/flyte/issues/211", + Type: []string{"object"}, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_RetryStrategy(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Strategy to be used to Retry a node that is in RetryableFailure state", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "minAttempts": { + SchemaProps: spec.SchemaProps{ + Description: "MinAttempts implies the atleast n attempts to try this node before giving up. The atleast here is because we may fail to write the attempt information and end up retrying again. Also `0` and `1` both mean atleast one attempt will be done. 0 is a degenerate case.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + Required: []string{"minAttempts"}, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_TaskExecutionIdentifier(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_TaskNodeStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "phase": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int32", + }, + }, + "phaseVersion": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int64", + }, + }, + "pState": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "byte", + }, + }, + "psv": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int64", + }, + }, + "tick": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int64", + }, + }, + "updAt": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "date-time", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_TaskPluginOverride(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "PluginsIDs": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "MissingPluginBehavior": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + Required: []string{"MissingPluginBehavior"}, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_TaskResourceSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Defines a set of configurable resources of different types that a task can request or apply as limits.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "CPU": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + }, + }, + "Memory": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + }, + }, + "EphemeralStorage": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + }, + }, + "Storage": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + }, + }, + "GPU": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_TaskResources(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Defines the complete closure of compute resources a task can request and apply as limits.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "Requests": { + SchemaProps: spec.SchemaProps{ + Description: "If the node where a task is running has enough of a resource available, a container may use more resources than its request for that resource specifies.", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskResourceSpec"), + }, + }, + "Limits": { + SchemaProps: spec.SchemaProps{ + Description: "A hard limit, a task cannot consume resources greater than the limit specifies.", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskResourceSpec"), + }, + }, + }, + Required: []string{"Requests", "Limits"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.TaskResourceSpec"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_TaskSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "TaskTemplate": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.TaskTemplate"), + }, + }, + }, + Required: []string{"TaskTemplate"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.TaskTemplate"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_WorkflowExecutionIdentifier(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_WorkflowMeta(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "eventVersion": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_WorkflowNodeSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "launchPlanRefId": { + SchemaProps: spec.SchemaProps{ + Description: "Either one of the two", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Identifier"), + }, + }, + "subWorkflowRef": { + SchemaProps: spec.SchemaProps{ + Description: "We currently want the SubWorkflow to be completely contained in the node. this is because We use the node status to store the information of the execution. Important Note: This may cause a bloat in case we use the same SubWorkflow in multiple nodes. The recommended technique for that is to use launch plan refs. This is because we will end up executing the launch plan refs as disparate executions in Flyte propeller. This is potentially better as it prevents us from hitting the storage limit in etcd Workflow *WorkflowSpec `json:\"workflow,omitempty\"`", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Identifier"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_WorkflowNodeStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "phase": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int32", + }, + }, + "executionError": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.ExecutionError"), + }, + }, + }, + Required: []string{"phase", "executionError"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/core.ExecutionError"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_WorkflowSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "WorkflowSpec is the spec for the actual Flyte Workflow (DAG)", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "id": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "nodes": { + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeSpec"), + }, + }, + }, + }, + }, + "connections": { + SchemaProps: spec.SchemaProps{ + Description: "Defines the set of connections (both data dependencies and execution dependencies) that the graph is formed of. The execution engine will respect and follow these connections as it determines which nodes can and should be executed. Deprecated: Please use Connections", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.DeprecatedConnections"), + }, + }, + "edges": { + SchemaProps: spec.SchemaProps{ + Description: "Defines the set of connections (both data dependencies and execution dependencies) that the graph is formed of. The execution engine will respect and follow these connections as it determines which nodes can and should be executed.", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Connections"), + }, + }, + "onFailure": { + SchemaProps: spec.SchemaProps{ + Description: "Defines a single node to execute in case the system determined the Workflow has failed.", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeSpec"), + }, + }, + "outputs": { + SchemaProps: spec.SchemaProps{ + Description: "Defines the declaration of the outputs types and names this workflow is expected to generate.", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.OutputVarMap"), + }, + }, + "outputBindings": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Defines the data links used to construct the final outputs of the workflow. Bindings will typically refer to specific outputs of a subset of the nodes executed in the Workflow. When executing the end-node, the execution engine will traverse these bindings and assemble the final set of outputs of the workflow.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Binding"), + }, + }, + }, + }, + }, + "onFailurePolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Defines the policy for handling failures whether it's to fail immediately, or let the nodes run to completion.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + Required: []string{"id", "nodes", "connections", "edges"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Binding", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.Connections", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.DeprecatedConnections", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeSpec", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.OutputVarMap"}, + } +} + +func schema_pkg_apis_flyteworkflow_v1alpha1_WorkflowStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "phase": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int32", + }, + }, + "startedAt": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + }, + }, + "stoppedAt": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + }, + }, + "lastUpdatedAt": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "dataDir": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "outputRef": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "nodeStatus": { + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeStatus"), + }, + }, + }, + }, + }, + "failedAttempts": { + SchemaProps: spec.SchemaProps{ + Description: "Number of Attempts completed with rounds resulting in error. this is used to cap out poison pill workflows that spin in an error loop. The value should be set at the global level and will be enforced. At the end of the retries the workflow will fail", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "error": { + SchemaProps: spec.SchemaProps{ + Description: "Stores the Error during the Execution of the Workflow. It is optional and usually associated with Failing/Failed state only", + Ref: ref("github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.ExecutionError"), + }, + }, + }, + Required: []string{"phase"}, + }, + }, + Dependencies: []string{ + "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.ExecutionError", "github.com/flyteorg/flytepropeller/pkg/apis/flyteworkflow/v1alpha1.NodeStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + } +} diff --git a/pkg/apis/flyteworkflow/v1alpha1/tasks.go b/pkg/apis/flyteworkflow/v1alpha1/tasks.go index e2bef531c..48e2c3aaa 100644 --- a/pkg/apis/flyteworkflow/v1alpha1/tasks.go +++ b/pkg/apis/flyteworkflow/v1alpha1/tasks.go @@ -7,6 +7,7 @@ import ( "github.com/golang/protobuf/jsonpb" ) +// +kubebuilder:validation:Type=object type TaskSpec struct { *core.TaskTemplate } diff --git a/pkg/apis/flyteworkflow/v1alpha1/workflow.go b/pkg/apis/flyteworkflow/v1alpha1/workflow.go index 0b4e6f3a3..2683ea6c0 100644 --- a/pkg/apis/flyteworkflow/v1alpha1/workflow.go +++ b/pkg/apis/flyteworkflow/v1alpha1/workflow.go @@ -20,7 +20,7 @@ const EndNodeID = "end-node" // +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object - +// +kubebuilder:resource:shortName=fly // FlyteWorkflow: represents one Execution Workflow object type FlyteWorkflow struct { metav1.TypeMeta `json:",inline"` @@ -153,8 +153,9 @@ func (in *FlyteWorkflow) GetRawOutputDataConfig() RawOutputDataConfig { return in.RawOutputDataConfig } +// +kubebuilder:validation:Type=object type Inputs struct { - *core.LiteralMap + *core.LiteralMap `json:",inline"` } func (in *Inputs) UnmarshalJSON(b []byte) error { @@ -183,8 +184,8 @@ func (in *Inputs) DeepCopyInto(out *Inputs) { // Deprecated: Please use Connections instead type DeprecatedConnections struct { - DownstreamEdges map[NodeID][]NodeID - UpstreamEdges map[NodeID][]NodeID + DownstreamEdges map[NodeID][]NodeID `json:"DownstreamEdges,omitempty"` + UpstreamEdges map[NodeID][]NodeID `json:"UpstreamEdges,omitempty"` } func (in *DeprecatedConnections) UnmarshalJSON(b []byte) error { @@ -254,6 +255,7 @@ type WorkflowSpec struct { // Defines the data links used to construct the final outputs of the workflow. Bindings will typically // refer to specific outputs of a subset of the nodes executed in the Workflow. When executing the end-node, // the execution engine will traverse these bindings and assemble the final set of outputs of the workflow. + // +listType=atomic OutputBindings []*Binding `json:"outputBindings,omitempty"` // Defines the policy for handling failures whether it's to fail immediately, or let the nodes run