-
Notifications
You must be signed in to change notification settings - Fork 17
Expand file tree
/
Copy pathACS::ECS::SMCConversionConstantByJqScript.json
More file actions
87 lines (87 loc) · 1.79 KB
/
ACS::ECS::SMCConversionConstantByJqScript.json
File metadata and controls
87 lines (87 loc) · 1.79 KB
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
{
"FormatVersion": "OOS-2019-06-01",
"Description": {
"name-en": "ACS::ECS::SMCConversionConstantByJqScript",
"name-zh-cn": "通过Jq脚本转化常量",
"en": "Execute jq script to convert string constant",
"zh-cn": "执行Jq脚本来转化字符串"
},
"Parameters": {
"parameter": {
"Description": {
"en": "The constant parameter.",
"zh-cn": "常量参数。"
},
"Type": "String"
},
"jqScript": {
"Description": {
"en": "The jq script(The script must begin with .[0] | 'your jq script')",
"zh-cn": "Jq脚本(Jq脚本必须以 \".[0] |\" 为起始)"
},
"Type": "List"
}
},
"Tasks": [
{
"Name": "placeHolder",
"Action": "ACS::Choice",
"Description": {
"en": "PlaceHolder for conver constant",
"zh-cn": "转化参数的占位"
},
"Properties": {
"DefaultTask": "ACS::END",
"Choices": [
{
"When": {
"Fn::Equals": [
1,
1
]
},
"NextTask": "ACS::END"
}
]
}
}
],
"Outputs": {
"firstValue": {
"Type": "String",
"Value": {
"Fn::Jq": [
"First",
{
"Fn::Jq": [
"First",
".[0]",
"{{ jqScript }}"
]
},
[
"{{ parameter }}"
]
]
}
},
"secondValue": {
"Type": "String",
"Value": {
"Fn::Jq": [
"First",
{
"Fn::Jq": [
"First",
".[1]",
"{{ jqScript }}"
]
},
[
"{{ parameter }}"
]
]
}
}
}
}