e067a7dfd61511555a679e3d1163b006ea447c67
[ccsdk/cds.git] /
1 {
2   "metadata": {
3     "template_author": "Brinda Santh Muthuramalingam",
4     "author-email": "brindasanth@in.ibm.com",
5     "user-groups": "ADMIN, OPERATION",
6     "template_name": "baseconfiguration",
7     "template_version": "1.0.0",
8     "template_tags": "brinda, tosca"
9   },
10   "imports": [
11     {
12       "file": "Definitions/types.json"
13     }
14   ],
15   "topology_template": {
16     "inputs": {
17       "request-id": {
18         "required": true,
19         "type": "string"
20       },
21       "action-name": {
22         "required": true,
23         "type": "string"
24       },
25       "scope-type": {
26         "required": true,
27         "type": "string"
28       },
29       "hostname": {
30         "required": true,
31         "type": "string"
32       }
33     },
34     "node_templates": {
35       "activate-process": {
36         "type": "dg-activate",
37         "properties": {
38           "process-name": {
39             "get_input": "action-name"
40           },
41           "version": {
42             "get_property": [
43               "SELF",
44               "process-name"
45             ]
46           },
47           "content": {
48             "get_artifact": [
49               "SELF",
50               "dg-activate-process"
51             ]
52           }
53         },
54         "artifacts": {
55           "dg-activate-process": {
56             "type": "artifact-directed-graph",
57             "file": "Plans/ActivateProcess.bpmn"
58           }
59         }
60       },
61       "resource-assignment": {
62         "type": "component-resource-assignment",
63         "properties": {
64           "request-id": "1234"
65         },
66         "interfaces": {
67           "DefaultComponentNode": {
68             "operations": {
69               "process": {
70                 "inputs": {
71                   "action-name": {
72                     "get_input": "action-name"
73                   },
74                   "resource-type": "vnf-type",
75                   "request-id": {
76                     "get_input": "request-id"
77                   },
78                   "resource-id": {
79                     "get_input": "hostname"
80                   },
81                   "template-content": {
82                     "get_artifact": [
83                       "SELF",
84                       "baseconfig-template"
85                     ]
86                   },
87                   "mapping-content": {
88                     "get_artifact": [
89                       "SELF",
90                       "baseconfig-mapping"
91                     ]
92                   }
93                 },
94                 "outputs": {
95                   "resource-assignment-params": {
96                     "get_attribute": [
97                       "SELF",
98                       "assignment-params"
99                     ]
100                   },
101                   "status": "success"
102                 }
103               }
104             }
105           }
106         },
107         "artifacts": {
108           "baseconfig-template": {
109             "type": "artifact-template-velocity",
110             "file": "Templates/baseconfig-template.vtl"
111           },
112           "baseconfig-mapping": {
113             "type": "artifact-mapping-resource",
114             "file": "Mappings/baseconfig-mapping.json"
115           }
116         }
117       },
118       "resource-assignment-py": {
119         "type": "component-resource-assignment",
120         "properties": {
121           "request-id": "1234"
122         },
123         "interfaces": {
124           "DefaultComponentNode": {
125             "operations": {
126               "process": {
127                 "implementation": {
128                   "primary": "component-script"
129                 },
130                 "inputs": {
131                   "action-name": {
132                     "get_input": "action-name"
133                   }
134                 },
135                 "outputs": {
136                   "resource-assignment-params": "",
137                   "status": ""
138                 }
139               }
140             }
141           }
142         },
143         "artifacts": {
144           "component-script": {
145             "type": "artifact-script-python",
146             "file": "Scripts/SamplePythonComponentNode.py"
147           }
148         }
149       }
150     },
151     "workflows": {
152       "resource-assignment": {
153         "inputs": {
154           "request-id": {
155             "required": true,
156             "type": "string"
157           },
158           "action-name": {
159             "required": true,
160             "type": "string"
161           },
162           "scope-type": {
163             "required": true,
164             "type": "string"
165           },
166           "hostname": {
167             "required": true,
168             "type": "string"
169           }
170         },
171         "steps": {
172           "call-resource-assignment": {
173             "description": "Resource Assignment Workflow",
174             "target": "resource-assignment",
175             "activities": [
176               {
177                 "call_operation": "ResourceAssignmentNode.process"
178               }
179             ]
180           }
181         }
182       },
183       "activate": {
184         "inputs": {
185           "request-id": {
186             "required": true,
187             "type": "string"
188           },
189           "action-name": {
190             "required": true,
191             "type": "string"
192           },
193           "scope-type": {
194             "required": true,
195             "type": "string"
196           },
197           "hostname": {
198             "required": true,
199             "type": "string"
200           }
201         },
202         "steps": {
203           "call-resource-assignment": {
204             "description": "Netconf Activation Workflow",
205             "target": "resource-assignment",
206             "activities": [
207               {
208                 "call_operation": "ResourceAssignmentNode.process"
209               }
210             ]
211           }
212         }
213       }
214     }
215   }
216 }