-
Notifications
You must be signed in to change notification settings - Fork 4
/
c0017.yml
94 lines (83 loc) · 1.73 KB
/
c0017.yml
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
doc_meta: |
folder: call-func
title: assemble worlflow
head: |
You can use call func to assemble a sequential workflow
This demo shows that you can adjust the seqence of the callee tasks
The result of concret implementation of callee_task1/2 will be different depending on the input vars from the caller
sections:
- title: Note
content: |
Please take a look of the log to see what are the contextual vars in runtime are
- title: Demo
log: yes
notes:
goal:
- to test multiple call func task executions should pass
vars:
a: runtime-a
e: runtime-e
k: runtime-k
tasks:
-
name: callee_task1
task:
-
func: shell
vars:
a: callee-a
b: callee-b
c: callee-c
do:
- echo "exec ref-task1"
- |
echo """
vars:
a: {{.a}}
b: {{.b}}
c: {{.c}}
e: {{.e}}
k: {{.k}}
"""
-
name: task
desc:
task:
-
func: call
desc: call1
vars:
a: caller-ref-1a
b: caller-ref-1b
do:
- callee_task1
- callee_task2
-
func: call
desc: call2
vars:
a: caller-ref-2a
b: caller-ref-2b
do:
- callee_task2
- callee_task1
-
name: callee_task2
task:
-
func: shell
vars:
a: callee-a
b: callee-b
c: callee-c
do:
- echo "exec ref-task2"
- |
echo """
vars:
a: {{.a}}
b: {{.b}}
c: {{.c}}
e: {{.e}}
k: {{.k}}
"""