Skip to content

Commit

Permalink
Documentation (argoproj#4122)
Browse files Browse the repository at this point in the history
  • Loading branch information
YourPsychiatrist committed Sep 29, 2020
1 parent 3a508a3 commit 1e10e0c
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 0 deletions.
28 changes: 28 additions & 0 deletions docs/variables.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,33 @@
# Workflow Variables

Some fields in a workflow specification allow for variable references which are automatically substituted by Argo.

??? note "How to use variables"
Variables are enclosed in curly braces and **must not** include whitespace.

``` yaml
apiVersion: argoproj.io/v1alpha1
kind: Workflow
metadata:
generateName: hello-world-parameters-
spec:
entrypoint: whalesay
arguments:
parameters:
- name: message
value: hello world
templates:
- name: whalesay
inputs:
parameters:
- name: message
container:
image: docker/whalesay
command: [cowsay]
# args: ["{{ inputs.parameters.message }}"] <- bad
args: ["{{inputs.parameters.message}}"] # good
```

The following variables are made available to reference various metadata of a workflow:

## All Templates
Expand Down
2 changes: 2 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ google_analytics:
markdown_extensions:
- codehilite
- admonition
- pymdownx.superfences
- pymdownx.details
- toc:
permalink: true
nav:
Expand Down

0 comments on commit 1e10e0c

Please sign in to comment.