push addional code
[sdc.git] / openecomp-be / lib / openecomp-sdc-translator-lib / openecomp-sdc-translator-core / src / test / resources / mock / services / heattotosca / novatovolumeconnection / multiconnection / expectedoutputfiles / MainServiceTemplate.yaml
1 tosca_definitions_version: tosca_simple_yaml_1_0_0
2 metadata:
3   template_name: Main
4 imports:
5   ContrailComputeGlobalTypes:
6     file: ContrailComputeGlobalTypesServiceTemplate.yaml
7   CinderVolumeGlobalTypes:
8     file: CinderVolumeGlobalTypesServiceTemplate.yaml
9   ContrailVirtualNetworkGlobalType:
10     file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml
11   AbstractSubstituteGlobalTypes:
12     file: AbstractSubstituteGlobalTypesServiceTemplate.yaml
13   ContrailPortGlobalTypes:
14     file: ContrailPortGlobalTypesServiceTemplate.yaml
15   NeutronPortGlobalTypes:
16     file: NeutronPortGlobalTypesServiceTemplate.yaml
17   NeutronNetGlobalTypes:
18     file: NeutronNetGlobalTypesServiceTemplate.yaml
19   CommonGlobalTypes:
20     file: CommonGlobalTypesServiceTemplate.yaml
21   ContrailAbstractSubstituteGlobalTypes:
22     file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml
23   ContrailNetworkRuleGlobalType:
24     file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml
25   NeutronSecurityRulesGlobalTypes:
26     file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml
27   NovaServerGlobalTypes:
28     file: NovaServerGlobalTypesServiceTemplate.yaml
29   ContrailV2VirtualMachineInterfaceGlobalType:
30     file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml
31 node_types:
32   org.openecomp.resource.vfc.nodes.heat.cmaui:
33     derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server
34 topology_template:
35   inputs:
36     cmaui_names:
37       hidden: false
38       immutable: false
39       type: list
40       description: CMAUI1, CMAUI2 server names
41       entry_schema:
42         type: string
43     cmaui_cinder_volume_size:
44       label: CMAUI Cinder volume size
45       hidden: false
46       immutable: false
47       type: float
48       description: the size of the CMAUI Cinder volume
49     timezone:
50       label: timezone
51       hidden: false
52       immutable: false
53       type: string
54       description: timezone
55     security_group_name:
56       label: security group name
57       hidden: false
58       immutable: false
59       type: string
60       description: the name of security group
61     cmaui_volume:
62       label: CMAUI vm volume type
63       hidden: false
64       immutable: false
65       type: string
66       description: the name of the target volume backend
67     oam_network_netmask:
68       label: oam network netmask
69       hidden: false
70       immutable: false
71       type: string
72       description: oam network gateway
73     cmaui_volume_param1:
74       hidden: false
75       immutable: false
76       type: string
77       description: nova server id
78     cmaui_image:
79       hidden: false
80       immutable: false
81       type: string
82       description: Image for CMAUI server
83     vnf_id:
84       hidden: false
85       immutable: false
86       type: string
87       description: Unique ID for this VNF instance
88       default: This_is_ths_MMSC-CMAUI_id
89     cmaui_flavor:
90       hidden: false
91       immutable: false
92       type: string
93       description: Flavor for CMAUI server
94     oam_network_gateway:
95       label: oam network gateway
96       hidden: false
97       immutable: false
98       type: string
99       description: oam network gateway
100     cmaui_volume_param2:
101       hidden: false
102       immutable: false
103       type: string
104       description: nova server id
105     availability_zone_0:
106       label: availabilityzone name
107       hidden: false
108       immutable: false
109       type: string
110       description: availabilityzone name
111     cmaui_oam_ips:
112       label: CMAUI oam_net IP addresses
113       hidden: false
114       immutable: false
115       type: list
116       description: CMAUI oam_net IP addresses
117       entry_schema:
118         type: string
119     external_dns:
120       label: dns server
121       hidden: false
122       immutable: false
123       type: string
124       description: dns server
125     oam_net_name:
126       hidden: false
127       immutable: false
128       type: string
129       description: UID of OAM network
130     CMAUI_volume_type:
131       label: CMAUI vm volume type
132       hidden: false
133       immutable: false
134       type: string
135       description: the name of the target volume backend
136     external_ntp:
137       label: ntp server
138       hidden: false
139       immutable: false
140       type: string
141       description: ntp server
142   node_templates:
143     cmaui_port_2:
144       type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port
145       properties:
146         replacement_policy: AUTO
147         security_groups:
148         - get_input: security_group_name
149         fixed_ips:
150         - ip_address:
151             get_input:
152             - cmaui_oam_ips
153             - 0
154         network:
155           get_input: oam_net_name
156       requirements:
157       - binding:
158           capability: tosca.capabilities.network.Bindable
159           node: server_cmaui2
160           relationship: tosca.relationships.network.BindsTo
161     server_cmaui2:
162       type: org.openecomp.resource.vfc.nodes.heat.cmaui
163       properties:
164         flavor:
165           get_input: cmaui_flavor
166         availability_zone:
167           get_input: availability_zone_0
168         image:
169           get_input: cmaui_image
170         metadata:
171           vnf_id:
172             get_input: vnf_id
173         user_data_format: RAW
174         name:
175           get_input:
176           - cmaui_names
177           - 0
178       requirements:
179       - local_storage:
180           capability: tosca.capabilities.Attachment
181           node: cmaui_volume2
182           relationship: cmaui_volume_attachment3
183     server_cmaui1:
184       type: org.openecomp.resource.vfc.nodes.heat.cmaui
185       properties:
186         flavor:
187           get_input: cmaui_flavor
188         availability_zone:
189           get_input: availability_zone_0
190         image:
191           get_input: cmaui_image
192         metadata:
193           vnf_id:
194             get_input: vnf_id
195         user_data_format: RAW
196         name:
197           get_input:
198           - cmaui_names
199           - 0
200       requirements:
201       - local_storage:
202           capability: tosca.capabilities.Attachment
203           node: cmaui_volume1
204           relationship: cmaui_volume_attachment1
205       - local_storage:
206           capability: tosca.capabilities.Attachment
207           node: cmaui_volume2
208           relationship: cmaui_volume_attachment2
209     cmaui_volume1:
210       type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume
211       properties:
212         volume_type:
213           get_input: CMAUI_volume_type
214         size: '(get_input : cmaui_cinder_volume_size) * 1024'
215     cmaui_volume2:
216       type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume
217       properties:
218         volume_type:
219           get_input: CMAUI_volume_type
220         size: '(get_input : cmaui_cinder_volume_size) * 1024'
221     cmaui_port_1:
222       type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port
223       properties:
224         replacement_policy: AUTO
225         security_groups:
226         - get_input: security_group_name
227         fixed_ips:
228         - ip_address:
229             get_input:
230             - cmaui_oam_ips
231             - 0
232         network:
233           get_input: oam_net_name
234       requirements:
235       - binding:
236           capability: tosca.capabilities.network.Bindable
237           node: server_cmaui1
238           relationship: tosca.relationships.network.BindsTo
239   relationship_templates:
240     cmaui_volume_attachment2:
241       type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo
242       properties:
243         volume_id:
244           get_input: cmaui_volume_param2
245         instance_uuid: server_cmaui1
246     cmaui_volume_attachment3:
247       type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo
248       properties:
249         volume_id:
250           get_input: cmaui_volume_param2
251         instance_uuid: server_cmaui2
252     cmaui_volume_attachment1:
253       type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo
254       properties:
255         volume_id:
256           get_input: cmaui_volume_param1
257         instance_uuid: server_cmaui1
258   groups:
259     addOn:
260       type: org.openecomp.groups.heat.HeatStack
261       properties:
262         heat_file: ../Artifacts/addOn.yml
263         description: cmaui server template for vMMSC
264       members:
265       - cmaui_port_2
266       - server_cmaui2
267       - server_cmaui1
268       - cmaui_port_1
269     main:
270       type: org.openecomp.groups.heat.HeatStack
271       properties:
272         heat_file: ../Artifacts/main.yml
273         description: volume
274       members:
275       - cmaui_volume1
276       - cmaui_volume2