Skip to content

Argo Workflows Param Quick Fix - Parameter Passing Errors

DodaTech Updated 2026-06-26 1 min read

Argo Workflows parameters pass values between templates and into workflow steps. Incorrect parameter syntax or undefined parameters cause workflow submission failures. This guide covers the fix.

Quick Fix

Wrong

spec:
  entrypoint: main
  arguments:
    parameters:
    - name: message
      value: "hello"
  templates:
  - name: main
    steps:
    - - name: print
        template: print-msg

The issue: main template does not accept message parameter, so {{inputs.parameters.message}} in print-msg will be empty. The parameter is defined at workflow level but not passed to templates.

spec:
  entrypoint: main
  arguments:
    parameters:
    - name: message
      value: "hello"
  templates:
  - name: main
    inputs:
      parameters:
      - name: message
    steps:
    - - name: print
        template: print-msg
        arguments:
          parameters:
          - name: message
            value: "{{inputs.parameters.message}}"
  - name: print-msg
    inputs:
      parameters:
      - name: message
    container:
      image: alpine:latest
      command: ["/bin/sh", "-c"]
      args: ["echo '{{inputs.parameters.message}}'"]
# Expected output after applying the fix
# Parameter chain: workflow → main → print-msg
# Printed: "hello"
# Parameter propagation works correctly

Prevention

  • Declare parameters in each template's inputs.parameters
  • Pass parameters explicitly when calling sub-templates
  • Use {{inputs.parameters.<name>}} not {{workflow.parameters.<name>}} in sub-templates
  • Reference {{workflow.parameters.<name>}} directly in the entrypoint template only
  • Validate parameter propagation with argo get <workflow>

DodaTech Tools

Doda Browser's parameter inspector shows parameter values at each workflow level. DodaZIP archives parameter sets for each workflow run. Durga Antivirus Pro validates parameter values against injection patterns.

FAQ

What is the difference between workflow parameters and template parameters?

Workflow parameters are global inputs to the entire workflow. Template parameters are scoped to individual templates and must be explicitly passed from parent templates. ||| Can parameters have default values? Yes, use the default field in parameter definitions. If no value is provided at runtime, the default is used. Without a default, the parameter is required. ||| How do I pass parameters from one step to another? Use {{steps.<step-name>.outputs.parameters.<name>}} to reference output parameters of previous steps in the same template.

Built by the developers of DodaTech

Doda Browser, DodaZIP & Durga Antivirus Pro