[sdc] update code of sdc
[sdc.git] / openecomp-be / lib / openecomp-sdc-translator-lib / openecomp-sdc-translator-core / src / test / resources / mock / services / heattotosca / unifiedComposition / createAbstractSubstitute / twoComputesMultiplePorts / out / MainServiceTemplate.yaml
1 tosca_definitions_version: tosca_simple_yaml_1_0_0
2 metadata:
3   template_name: Main
4 imports:
5 - openecomp_heat_index:
6     file: openecomp-heat/_index.yml
7 - GlobalSubstitutionTypes:
8     file: GlobalSubstitutionTypesServiceTemplate.yaml
9 node_types:
10   org.openecomp.resource.vfc.nodes.heat.FSB:
11     derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server
12 topology_template:
13   inputs:
14     fsb1-name:
15       label: FSB1_name
16       hidden: false
17       immutable: false
18       type: string
19       description: FSB1_name
20     fsb2-name:
21       label: FSB2_name
22       hidden: false
23       immutable: false
24       type: string
25       description: FSB2_name
26     cmaui_cinder_volume_size:
27       label: volume size
28       hidden: false
29       immutable: false
30       type: float
31       description: my volume size 320GB
32     fsb-flavor:
33       label: FSB1_flavor
34       hidden: false
35       immutable: false
36       type: string
37       description: FSB1_flavor
38     fsb-image:
39       label: FSB1_image
40       hidden: false
41       immutable: false
42       type: string
43       description: FSB1_image
44     fsb1-Internal1-mac:
45       label: FSB1_internal_mac
46       hidden: false
47       immutable: false
48       type: string
49       description: FSB1_internal_mac
50     fsb1-Internal2-mac:
51       label: FSB1_internal_mac
52       hidden: false
53       immutable: false
54       type: string
55       description: FSB1_internal_mac
56     fsb1-zone:
57       label: FSB1_zone
58       hidden: false
59       immutable: false
60       type: string
61       description: FSB1_zone
62     fsb2_zone:
63       label: FSB2_zone
64       hidden: false
65       immutable: false
66       type: string
67       description: FSB2_zone
68     network_name:
69       hidden: false
70       immutable: false
71       type: string
72       description: prop
73     fsb2-Internal1-mac:
74       label: FSB1_internal_mac
75       hidden: false
76       immutable: false
77       type: string
78       description: FSB1_internal_mac
79     fsb2-Internal2-mac:
80       label: FSB1_internal_mac
81       hidden: false
82       immutable: false
83       type: string
84       description: FSB1_internal_mac
85     fsb1-oam-ip:
86       hidden: false
87       immutable: false
88       type: string
89       description: prop
90   node_templates:
91     FSB2_Internal2:
92       type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port
93       properties:
94         mac_address:
95           get_input: fsb2-Internal2-mac
96         network: Internal2-net-fsb2-Internal2
97       requirements:
98       - binding:
99           capability: tosca.capabilities.network.Bindable
100           node: FSB2_template
101           relationship: tosca.relationships.network.BindsTo
102     FSB2_Internal1:
103       type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port
104       properties:
105         mac_address:
106           get_input: fsb2-Internal1-mac
107         network: Internal2-net-fsb2-Internal1
108       requirements:
109       - binding:
110           capability: tosca.capabilities.network.Bindable
111           node: FSB1_template
112           relationship: tosca.relationships.network.BindsTo
113     FSB1_Internal2:
114       type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port
115       properties:
116         mac_address:
117           get_input: fsb1-Internal2-mac
118         network: Internal1-net-fsb1-Internal2
119       requirements:
120       - binding:
121           capability: tosca.capabilities.network.Bindable
122           node: FSB2_template
123           relationship: tosca.relationships.network.BindsTo
124       - link:
125           capability: tosca.capabilities.network.Linkable
126           node: jsa_net1
127           relationship: tosca.relationships.network.LinksTo
128     FSB1_Internal1:
129       type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port
130       properties:
131         mac_address:
132           get_input: fsb1-Internal1-mac
133         network: Internal1-net-fsb1-Internal1
134       requirements:
135       - binding:
136           capability: tosca.capabilities.network.Bindable
137           node: FSB1_template
138           relationship: tosca.relationships.network.BindsTo
139       - link:
140           capability: tosca.capabilities.network.Linkable
141           node: jsa_net1
142           relationship: tosca.relationships.network.LinksTo
143     jsa_net1:
144       type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net
145       properties:
146         shared: true
147         network_name:
148           get_attribute:
149           - FSB1_Internal1
150           - network_id
151         dhcp_agent_ids:
152           get_attribute:
153           - FSB1_template
154           - addresses
155         tenant_id:
156           get_attribute:
157           - FSB2_Internal2
158           - network_id
159         qos_policy:
160           get_attribute:
161           - FSB2_Internal2
162           - network_id
163     FSB1_template:
164       type: org.openecomp.resource.vfc.nodes.heat.FSB
165       properties:
166         flavor:
167           get_input: fsb-flavor
168         image:
169           get_input: fsb-image
170         admin_pass: STATIC-DATA-FSB1
171         user_data: OPTIONAL-DATA-FSB1
172         availability_zone:
173           get_input: fsb1_zone
174         metadata:
175           write_files:
176           - path: /path1/etc/sysconfig/network-scripts/ifcfg-eth0
177           - path: /path2/etc/sysconfig/network-scripts/ifcfg-eth1
178         name:
179           get_input: fsb1-name
180       requirements:
181       - local_storage:
182           capability: tosca.capabilities.Attachment
183           node: cmaui_volume1
184           relationship: cmaui_volume_attachment
185       - local_storage:
186           capability: tosca.capabilities.Attachment
187           node: cmaui_volume2
188           relationship: cmaui_volume_attachment
189     FSB2_template:
190       type: org.openecomp.resource.vfc.nodes.heat.FSB
191       properties:
192         flavor:
193           get_input: fsb-flavor
194         image:
195           get_input: fsb-image
196         admin_pass: STATIC-DATA-FSB2
197         availability_zone:
198           get_input: fsb2_zone
199         metadata:
200           write_files:
201           - path: /path3/etc/sysconfig/network-scripts/ifcfg-eth0
202           - path: /path4/etc/sysconfig/network-scripts/ifcfg-eth1
203         name:
204           get_input: fsb2-name
205       requirements:
206       - local_storage:
207           capability: tosca.capabilities.Attachment
208           node: cmaui_volume3
209           relationship: cmaui_volume_attachment
210       - local_storage:
211           capability: tosca.capabilities.Attachment
212           node: cmaui_volume4
213           relationship: cmaui_volume_attachment
214     cmaui_volume1:
215       type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume
216       properties:
217         volume_type:
218           get_input: CMAUI_volume_type
219         size: '(get_input : cmaui_cinder_volume_size) * 1024'
220     cmaui_volume2:
221       type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume
222       properties:
223         volume_type:
224           get_input: CMAUI_volume_type
225         size: '(get_input : cmaui_cinder_volume_size) * 1024'
226     cmaui_volume3:
227       type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume
228       properties:
229         volume_type:
230           get_input: CMAUI_volume_type
231         size: '(get_input : cmaui_cinder_volume_size) * 1024'
232     cmaui_volume4:
233       type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume
234       properties:
235         volume_type:
236           get_input: CMAUI_volume_type
237         size: '(get_input : cmaui_cinder_volume_size) * 1024'
238     abstract_FSB:
239       type: org.openecomp.resource.abstract.nodes.FSB
240       directives:
241       - substitutable
242       properties:
243         port_FSB1_Internal_mac_address:
244           get_input: fsb1-Internal1-mac
245         compute_FSB_user_data:
246         - OPTIONAL-DATA-FSB1
247         - null
248         vm_flavor_name:
249           get_input: fsb-flavor
250         vm_image_name:
251           get_input: fsb-image
252         compute_FSB_admin_pass:
253         - STATIC-DATA-FSB1
254         - STATIC-DATA-FSB2
255         port_FSB1_Internal_network:
256         - Internal1-net-fsb1-Internal1
257         - Internal1-net-fsb1-Internal2
258         port_FSB2_Internal_mac_address:
259           get_input: fsb2-Internal1-mac
260         port_FSB2_Internal_network:
261         - Internal2-net-fsb2-Internal1
262         - Internal2-net-fsb2-Internal2
263         compute_FSB_metadata:
264         - write_files:
265           - path: /path1/etc/sysconfig/network-scripts/ifcfg-eth0
266           - path: /path2/etc/sysconfig/network-scripts/ifcfg-eth1
267         - write_files:
268           - path: /path3/etc/sysconfig/network-scripts/ifcfg-eth0
269           - path: /path4/etc/sysconfig/network-scripts/ifcfg-eth1
270         compute_FSB_availability_zone:
271         - get_input: fsb1_zone
272         - get_input: fsb2_zone
273         compute_FSB_name:
274         - get_input: fsb1-name
275         - get_input: fsb2-name
276         service_template_filter:
277           substitute_service_template: Nested_FSBServiceTemplate.yaml
278           count: 2
279         index_value:
280           get_property:
281           - SELF
282           - service_template_filter
283           - index_value
284   groups:
285     ep-jsa_net_group:
286       type: org.openecomp.groups.heat.HeatStack
287       properties:
288         heat_file: ../Artifacts/ep-jsa_net.yaml
289         description: |
290           Version 2.0 02-09-2016 (Authors: John Doe, user PROD)
291       members:
292       - FSB1_Internal1
293       - FSB1_Internal2
294       - FSB2_Internal1
295       - FSB2_Internal2
296       - FSB1_template
297       - FSB2_template