Argo · JSON Structure

Argo Workflows Workflow Spec Structure

Specification of a workflow

Type: object Properties: 16
CNCFCI/CDGitOpsKubernetesOpen SourceProgressive DeliveryWorkflow Engine

WorkflowSpec is a JSON Structure definition published by Argo, describing 16 properties. It conforms to the https://json-structure.org/meta/core/v0/# meta-schema.

Properties

entrypoint arguments templates serviceAccountName volumes activeDeadlineSeconds nodeSelector tolerations parallelism ttlStrategy podGC workflowTemplateRef archiveLogs hooks onExit retryStrategy

Meta-schema: https://json-structure.org/meta/core/v0/#

JSON Structure

Raw ↑
{
  "$schema": "https://json-structure.org/meta/core/v0/#",
  "$id": "https://raw.githubusercontent.com/api-evangelist/argo/refs/heads/main/json-structure/argo-workflows-workflow-spec-structure.json",
  "name": "WorkflowSpec",
  "description": "Specification of a workflow",
  "type": "object",
  "properties": {
    "entrypoint": {
      "type": "string",
      "description": "The name of the entrypoint template"
    },
    "arguments": {
      "$ref": "#/components/schemas/Arguments"
    },
    "templates": {
      "type": "array",
      "description": "List of workflow templates",
      "items": {
        "$ref": "#/components/schemas/Template"
      }
    },
    "serviceAccountName": {
      "type": "string",
      "description": "Service account to run workflow pods"
    },
    "volumes": {
      "type": "array",
      "description": "Volumes available to workflow steps",
      "items": {
        "type": "object"
      }
    },
    "activeDeadlineSeconds": {
      "type": "int64",
      "description": "Duration in seconds before workflow times out"
    },
    "nodeSelector": {
      "type": "object",
      "additionalProperties": {
        "type": "string"
      }
    },
    "tolerations": {
      "type": "array",
      "items": {
        "type": "object"
      }
    },
    "parallelism": {
      "type": "int32",
      "description": "Maximum number of parallel running pods"
    },
    "ttlStrategy": {
      "type": "object",
      "description": "Strategy for cleaning up completed workflows",
      "properties": {
        "secondsAfterCompletion": {
          "type": "int32"
        },
        "secondsAfterSuccess": {
          "type": "int32"
        },
        "secondsAfterFailure": {
          "type": "int32"
        }
      }
    },
    "podGC": {
      "type": "object",
      "description": "Strategy for garbage collecting completed pods",
      "properties": {
        "strategy": {
          "type": "string",
          "enum": [
            "OnPodCompletion",
            "OnPodSuccess",
            "OnWorkflowCompletion",
            "OnWorkflowSuccess"
          ]
        }
      }
    },
    "workflowTemplateRef": {
      "type": "object",
      "description": "Reference to a WorkflowTemplate",
      "properties": {
        "name": {
          "type": "string"
        },
        "clusterScope": {
          "type": "boolean"
        }
      }
    },
    "archiveLogs": {
      "type": "boolean",
      "description": "Whether to archive workflow logs"
    },
    "hooks": {
      "type": "object",
      "description": "Lifecycle hooks for the workflow",
      "additionalProperties": {
        "type": "object"
      }
    },
    "onExit": {
      "type": "string",
      "description": "Template to execute on workflow exit"
    },
    "retryStrategy": {
      "$ref": "#/components/schemas/RetryStrategy"
    }
  }
}