Skip to content

Commit

Permalink
docs: document the WorkflowTemplate workflowMetadata feature (#5177)
Browse files Browse the repository at this point in the history
  • Loading branch information
crenshaw-dev authored Feb 24, 2021
1 parent 71bf06c commit a46ff82
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions docs/workflow-templates.md
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,23 @@ spec:
args: ["{{inputs.parameters.message}}"]
```

### Adding labels/annotations to Workflows with `workflowMetadata`

> 2.10.2 and after

To automatically add labels and/or annotations to Workflows created from `WorkflowTemplates`, use `workflowMetadata`.

```yaml
apiVersion: argoproj.io/v1alpha1
kind: WorkflowTemplate
metadata:
name: workflow-template-submittable
spec:
workflowMetadata:
labels:
example-label: example-value
```

## Referencing other `WorkflowTemplates`

You can reference `templates` from another `WorkflowTemplates` (see the [difference between the two](#workflowtemplate-vs-template)) using a `templateRef` field.
Expand Down

0 comments on commit a46ff82

Please sign in to comment.