[SDC-29] Amdocs OnBoard 1707 initial commit.
[sdc.git] / openecomp-be / lib / openecomp-sdc-translator-lib / openecomp-sdc-translator-core / src / test / resources / mock / heat / resources / OS_Nova_Server / expectedoutputfiles / 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 node_types:
8   org.openecomp.resource.vfc.nodes.heat.FSB2:
9     derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server
10   org.openecomp.resource.vfc.nodes.heat.FSB1:
11     derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server
12   org.openecomp.resource.vfc.nodes.heat.pcm_server:
13     derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server
14   org.openecomp.resource.vfc.nodes.heat.pcrf_psm_server:
15     derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server
16 topology_template:
17   inputs:
18     Internal2_name:
19       label: Internal2_name
20       hidden: false
21       immutable: false
22       type: string
23       description: Internal2_name
24     Internal1_shared:
25       label: Internal1_shared
26       hidden: false
27       immutable: false
28       type: string
29       description: Internal1_shared
30     FSB1_volume_name:
31       label: FSB1_volume
32       hidden: false
33       immutable: false
34       type: string
35       description: FSB1_volume_1
36     jsa_cidr:
37       label: jsa_cidr
38       hidden: false
39       immutable: false
40       type: string
41       description: jsa_cidr
42       default: 107.243.7.128/26
43     availabilityzone_name:
44       label: availabilityzone_name
45       hidden: false
46       immutable: false
47       type: string
48       description: availabilityzone_name
49     fsb1-name:
50       label: FSB1_name
51       hidden: false
52       immutable: false
53       type: string
54       description: FSB1_name
55     pcm_image_name:
56       label: pcm_image_name
57       hidden: false
58       immutable: false
59       type: string
60       description: pcm_image_name
61     Internal2_external:
62       label: Internal2_external
63       hidden: false
64       immutable: false
65       type: string
66       description: Internal2_external
67     Internal2_forwarding_mode:
68       label: Internal2_forwarding_mode
69       hidden: false
70       immutable: false
71       type: string
72       description: Internal2_forwarding_mode
73     pcrf_psm_flavor_name:
74       label: pcrf_psm_flavor_name
75       hidden: false
76       immutable: false
77       type: string
78       description: pcrf_psm_flavor_name
79     pcrf_psm_image_name:
80       label: pcrf_psm_image_name
81       hidden: false
82       immutable: false
83       type: string
84       description: pcrf_psm_image_name
85     pcrf_vnf_id:
86       hidden: false
87       immutable: false
88       type: string
89       description: prop
90     FSB_1_image:
91       label: MME_FSB1
92       hidden: false
93       immutable: false
94       type: string
95       description: MME_FSB1_15B-CP04-r5a01
96     snapshot01:
97       hidden: false
98       immutable: false
99       type: string
100       description: prop
101     volume_size:
102       label: volume size
103       hidden: false
104       immutable: false
105       type: float
106       description: my volume size 320GB
107     snapshot02:
108       hidden: false
109       immutable: false
110       type: string
111       description: prop
112     fsb1-Internal1-mac:
113       label: FSB1_internal_mac
114       hidden: false
115       immutable: false
116       type: string
117       description: FSB1_internal_mac
118     Internal2_shared:
119       label: Internal2_shared
120       hidden: false
121       immutable: false
122       type: string
123       description: Internal2_shared
124     pcm_server_name:
125       label: pcm_server_name
126       hidden: false
127       immutable: false
128       type: string
129       description: pcm_server_name
130     cps_net_mask:
131       hidden: false
132       immutable: false
133       type: string
134       description: prop
135     Internal1_net_name:
136       label: Internal1_net_name
137       hidden: false
138       immutable: false
139       type: string
140       description: Internal1_net_name
141     oam_net_name:
142       label: oam_net_name
143       hidden: false
144       immutable: false
145       type: string
146       description: oam_net_name
147     fsb1-flavor:
148       label: FSB1_flavor
149       hidden: false
150       immutable: false
151       type: string
152       description: FSB1_flavor
153     fsb1-Internal2-mac:
154       label: FSB1_internal_mac
155       hidden: false
156       immutable: false
157       type: string
158       description: FSB1_internal_mac
159     pcm_vol_01:
160       hidden: false
161       immutable: false
162       type: string
163       description: prop
164     volume_type:
165       label: volume type
166       hidden: false
167       immutable: false
168       type: string
169       description: volume type Gold
170     fsb1-zone:
171       label: FSB1_zone
172       hidden: false
173       immutable: false
174       type: string
175       description: FSB1_zone
176     fsb_zone:
177       label: FSB1_zone
178       hidden: false
179       immutable: false
180       type: string
181       description: FSB1_zone
182     oam_net_gw:
183       hidden: false
184       immutable: false
185       type: string
186       description: prop
187     VMME_FSB1_boot_volume:
188       hidden: false
189       immutable: false
190       type: string
191     network_name:
192       hidden: false
193       immutable: false
194       type: string
195       description: prop
196     security_group_name:
197       hidden: false
198       immutable: false
199       type: list
200       description: CMAUI1, CMAUI2 server names
201       entry_schema:
202         type: string
203     cps_net_ip:
204       hidden: false
205       immutable: false
206       type: string
207       description: prop
208     jsa_net_name:
209       label: jsa_net_name
210       hidden: false
211       immutable: false
212       type: string
213       description: jsa_net_name
214       default: jsa_log_net_0
215     pcrf_psm_server_name:
216       label: pcrf_psm_server_name
217       hidden: false
218       immutable: false
219       type: string
220       description: pcrf_psm_server_name
221     pcm_flavor_name:
222       label: pcm_flavor_name
223       hidden: false
224       immutable: false
225       type: string
226       description: pcm_flavor_name
227     oam_net_id:
228       label: oam_net_id
229       hidden: false
230       immutable: false
231       type: string
232       description: oam_net_id
233     pcrf_cps_net_ip:
234       hidden: false
235       immutable: false
236       type: string
237       description: prop
238     fsb2-Internal1-mac:
239       label: FSB1_internal_mac
240       hidden: false
241       immutable: false
242       type: string
243       description: FSB1_internal_mac
244     Internal1_forwarding_mode:
245       label: Internal1_forwarding_mode
246       hidden: false
247       immutable: false
248       type: string
249       description: Internal1_forwarding_mode
250     pcrf_cps_net_name:
251       label: pcrf_cps_net_name
252       hidden: false
253       immutable: false
254       type: string
255       description: pcrf_cps_net_name
256     pcm_vol:
257       hidden: false
258       immutable: false
259       type: string
260       description: prop
261     cps_net_name:
262       label: cps_net_name
263       hidden: false
264       immutable: false
265       type: string
266       description: cps_net_name
267     oam_net_ip:
268       hidden: false
269       immutable: false
270       type: string
271       description: prop
272     oam_net_mask:
273       hidden: false
274       immutable: false
275       type: string
276       description: prop
277     fsb1-oam-ip:
278       hidden: false
279       immutable: false
280       type: string
281       description: prop
282     pcrf_security_group_name:
283       hidden: false
284       immutable: false
285       type: list
286       description: CMAUI1, CMAUI2 server names
287       entry_schema:
288         type: string
289     Internal1_external:
290       label: Internal1_external
291       hidden: false
292       immutable: false
293       type: string
294       description: Internal1_external
295   node_templates:
296     pcm_vol_02:
297       type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume
298       properties:
299         image:
300           get_input: FSB_1_image
301         volume_type:
302           get_input: volume_type
303         size: '(get_input : volume_size) * 1024'
304         read_only: true
305         name:
306           get_input: FSB1_volume_name
307     Internal2-net:
308       type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork
309       properties:
310         shared:
311           get_input: Internal2_shared
312         forwarding_mode:
313           get_input: Internal2_forwarding_mode
314         external:
315           get_input: Internal2_external
316         network_name:
317           get_input: Internal2_name
318     pcm_port_1:
319       type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port
320       properties:
321         ip_requirements:
322         - ip_version: 4
323           ip_count_required:
324             is_required: true
325           floating_ip_count_required:
326             is_required: false
327         security_groups:
328         - get_input: security_group_name
329         fixed_ips:
330         - ip_address:
331             get_input: oam_net_ip
332         mac_requirements:
333           mac_count_required:
334             is_required: false
335         network_role_tag: oam
336         network:
337           get_input: oam_net_name
338       requirements:
339       - binding:
340           capability: tosca.capabilities.network.Bindable
341           node: server_pcm
342           relationship: tosca.relationships.network.BindsTo
343     server_VolumeTest_snapshot02:
344       type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume
345       properties:
346         snapshot_id:
347           get_input: snapshot02
348     FSB1_Internal2:
349       type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port
350       properties:
351         ip_requirements:
352         - ip_version: 4
353           ip_count_required:
354             is_required: false
355           floating_ip_count_required:
356             is_required: false
357         mac_requirements:
358           mac_count_required:
359             is_required: true
360         mac_address:
361           get_input: fsb1-Internal2-mac
362         network: Internal2-net
363       requirements:
364       - link:
365           capability: tosca.capabilities.network.Linkable
366           node: Internal2-net
367           relationship: tosca.relationships.network.LinksTo
368       - binding:
369           capability: tosca.capabilities.network.Bindable
370           node: FSB1
371           relationship: tosca.relationships.network.BindsTo
372     server_VolumeTest_snapshot01:
373       type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume
374       properties:
375         snapshot_id:
376           get_input: snapshot01
377     FSB1_Internal1:
378       type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port
379       properties:
380         ip_requirements:
381         - ip_version: 4
382           ip_count_required:
383             is_required: false
384           floating_ip_count_required:
385             is_required: false
386         mac_requirements:
387           mac_count_required:
388             is_required: true
389         mac_address:
390           get_input: fsb1-Internal1-mac
391         network: Internal1-net
392       requirements:
393       - link:
394           capability: tosca.capabilities.network.Linkable
395           node: Internal1-net
396           relationship: tosca.relationships.network.LinksTo
397       - binding:
398           capability: tosca.capabilities.network.Bindable
399           node: FSB1
400           relationship: tosca.relationships.network.BindsTo
401     FSB1_OAM:
402       type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port
403       properties:
404         ip_requirements:
405         - ip_version: 4
406           ip_count_required:
407             is_required: true
408           floating_ip_count_required:
409             is_required: false
410         fixed_ips:
411         - ip_address:
412             get_input: fsb1-oam-ip
413         mac_requirements:
414           mac_count_required:
415             is_required: false
416         network_role_tag: oam
417         network:
418           get_input: oam_net_id
419       requirements:
420       - binding:
421           capability: tosca.capabilities.network.Bindable
422           node: FSB1
423           relationship: tosca.relationships.network.BindsTo
424     psm01_port_0:
425       type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port
426       properties:
427         ip_requirements:
428         - ip_version: 4
429           ip_count_required:
430             is_required: true
431           floating_ip_count_required:
432             is_required: false
433         security_groups:
434         - get_input: pcrf_security_group_name
435         fixed_ips:
436         - ip_address:
437             get_input: pcrf_cps_net_ip
438         mac_requirements:
439           mac_count_required:
440             is_required: false
441         network_role_tag: pcrf_cps
442         network:
443           get_input: pcrf_cps_net_name
444       requirements:
445       - binding:
446           capability: tosca.capabilities.network.Bindable
447           node: pcrf_server_psm
448           relationship: tosca.relationships.network.BindsTo
449     pcm_port_0:
450       type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port
451       properties:
452         ip_requirements:
453         - ip_version: 4
454           ip_count_required:
455             is_required: true
456           floating_ip_count_required:
457             is_required: false
458         security_groups:
459         - get_input: security_group_name
460         fixed_ips:
461         - ip_address:
462             get_input: cps_net_ip
463         mac_requirements:
464           mac_count_required:
465             is_required: false
466         network_role_tag: cps
467         network:
468           get_input: cps_net_name
469       requirements:
470       - binding:
471           capability: tosca.capabilities.network.Bindable
472           node: server_pcm
473           relationship: tosca.relationships.network.BindsTo
474     network:
475       type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork
476       properties:
477         network_name:
478           get_input: Internal1_net_name
479     server_pcm:
480       type: org.openecomp.resource.vfc.nodes.heat.pcm_server
481       properties:
482         flavor:
483           get_input: pcm_flavor_name
484         availability_zone:
485           get_input: availabilityzone_name
486         image:
487           get_input: pcm_image_name
488         config_drive: true
489         user_data_format: RAW
490         name:
491           get_input: pcm_server_name
492     Internal1-net:
493       type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork
494       properties:
495         shared:
496           get_input: Internal1_shared
497         forwarding_mode:
498           get_input: Internal1_forwarding_mode
499         external:
500           get_input: Internal1_external
501         network_name:
502           get_input: Internal1_net_name
503     pcrf_server_psm:
504       type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm_server
505       properties:
506         flavor:
507           get_input: pcrf_psm_flavor_name
508         availability_zone:
509           get_input: availabilityzone_name
510         image:
511           get_input: pcrf_psm_image_name
512         metadata:
513           vnf_id:
514             get_input: pcrf_vnf_id
515         config_drive: true
516         user_data_format: RAW
517         name:
518           get_input: pcrf_psm_server_name
519     server_VolumeTest:
520       type: org.openecomp.resource.vfc.nodes.heat.pcm_server
521       properties:
522         flavor:
523           get_input: pcm_flavor_name
524         availability_zone:
525           get_input: availabilityzone_name
526         image:
527           get_input: pcm_image_name
528         config_drive: true
529         user_data_format: RAW
530         name:
531           get_input: pcm_server_name
532       requirements:
533       - local_storage:
534           capability: tosca.capabilities.Attachment
535           node: pcm_vol_02
536           relationship: tosca.relationships.AttachesTo
537       - local_storage:
538           capability: tosca.capabilities.Attachment
539           node: server_VolumeTest_snapshot01
540           relationship: server_VolumeTest_4
541       - local_storage:
542           capability: tosca.capabilities.Attachment
543           node: server_VolumeTest_snapshot02
544           relationship: server_VolumeTest_5
545     FSB2:
546       type: org.openecomp.resource.vfc.nodes.heat.FSB2
547       properties:
548         flavor:
549           get_input: fsb1-flavor
550         availability_zone:
551           get_input: fsb_zone
552         name:
553           get_input: fsb1-name
554     FSB1:
555       type: org.openecomp.resource.vfc.nodes.heat.FSB1
556       properties:
557         flavor:
558           get_input: fsb1-flavor
559         availability_zone:
560           get_input: fsb_zone
561         metadata:
562           write_files:
563           - path: /etc/sysconfig/network-scripts/ifcfg-eth0
564             permissions: '0644'
565             content:
566               str_replace:
567                 template:
568                   get_artifact:
569                   - SELF
570                   - nimbus-ethernet
571                 params:
572                   $dev: eth0
573                   $netmask:
574                     get_input: cps_net_mask
575                   $ip:
576                     get_input: cps_net_ip
577           - path: /etc/sysconfig/network-scripts/ifcfg-eth1
578             permissions: '0644'
579             content:
580               str_replace:
581                 template:
582                   get_artifact:
583                   - SELF
584                   - nimbus-ethernet-gw
585                 params:
586                   $dev: eth1
587                   $netmask:
588                     get_input: oam_net_mask
589                   $gateway:
590                     get_input: oam_net_gw
591                   $ip:
592                     get_input: oam_net_ip
593         name:
594           get_input: fsb1-name
595       artifacts:
596         nimbus-ethernet-gw:
597           type: tosca.artifacts.Deployment
598           file: ../Artifacts/nimbus-ethernet-gw
599         nimbus-ethernet:
600           type: tosca.artifacts.Deployment
601           file: ../Artifacts/nimbus-ethernet
602   relationship_templates:
603     server_VolumeTest_4:
604       type: org.openecomp.relationships.VolumeAttachesTo
605       properties:
606         volume_id: server_VolumeTest_snapshot01
607         instance_uuid: server_VolumeTest
608         device: vdb
609     server_VolumeTest_5:
610       type: org.openecomp.relationships.VolumeAttachesTo
611       properties:
612         volume_id: server_VolumeTest_snapshot02
613         instance_uuid: server_VolumeTest
614   groups:
615     ep-jsa_net_group:
616       type: org.openecomp.groups.heat.HeatStack
617       properties:
618         heat_file: ../Artifacts/ep-jsa_net.yaml
619         description: |
620           Version 2.0 02-09-2016 (Authors: John Doe, user PROD)
621       members:
622       - pcm_vol_02
623       - Internal2-net
624       - pcm_port_1
625       - FSB1_Internal2
626       - FSB1_Internal1
627       - FSB1_OAM
628       - psm01_port_0
629       - pcm_port_0
630       - network
631       - server_pcm
632       - Internal1-net
633       - pcrf_server_psm
634       - server_VolumeTest
635       - FSB2
636       - FSB1