-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathartifact.yaml
37 lines (35 loc) · 1.05 KB
/
artifact.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
apiVersion: argoproj.io/v1alpha1
kind: Workflow
metadata:
generateName: artifact-passing-example-
spec:
entrypoint: artifact-passing-workflow
templates:
- name: artifact-passing-workflow
steps:
- - name: generate-data
template: generate-data
- - name: print-data
template: print-data
arguments:
artifacts:
- name: received-data
from: "{{steps.generate-data.outputs.artifacts.generated-data}}"
- name: generate-data
container:
image: alpine:3.7
command: [sh, -c]
args: [ "echo 'generating data...' && sleep 2 && echo 'Data generated successfully.' > /tmp/data.txt" ]
outputs:
artifacts:
- name: generated-data
path: /tmp/data.txt
- name: print-data
inputs:
artifacts:
- name: received-data
path: /tmp/data.txt
container:
image: alpine:3.7
command: [sh, -c]
args: [ "echo 'Printing received data:' && cat /tmp/data.txt" ]