Update OOF installation scripts
[demo.git] / heat / ONAP / onap_openstack_light.yaml
1 ##########################################################################
2 #
3 #==================LICENSE_START==========================================
4 #
5 #
6 # Copyright (c) 2017 AT&T Intellectual Property. All rights reserved.
7 #
8 # Licensed under the Apache License, Version 2.0 (the "License");
9 # you may not use this file except in compliance with the License.
10 # You may obtain a copy of the License at
11 #        http://www.apache.org/licenses/LICENSE-2.0
12 #
13 # Unless required by applicable law or agreed to in writing, software
14 # distributed under the License is distributed on an "AS IS" BASIS,
15 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 # See the License for the specific language governing permissions and
17 # limitations under the License.
18 #
19 #==================LICENSE_END============================================
20 #
21 # ECOMP is a trademark and service mark of AT&T Intellectual Property.
22 #
23 ##########################################################################
24
25 heat_template_version: 2015-10-15
26
27 description: Heat template to install ONAP components
28
29 ##############
30 #            #
31 # PARAMETERS #
32 #            #
33 ##############
34
35 parameters:
36
37   ##############################################
38   #                                            #
39   # Parameters used across all ONAP components #
40   #                                            #
41   ##############################################
42
43   public_net_id:
44     type: string
45     description: The ID of the Public network for floating IP address allocation
46
47   public_net_name:
48     type: string
49     description: The name of the Public network referred by public_net_id
50
51   ubuntu_1404_image:
52     type: string
53     description: Name of the Ubuntu 14.04 image
54
55   ubuntu_1604_image:
56     type: string
57     description: Name of the Ubuntu 16.04 image
58
59   flavor_small:
60     type: string
61     description: Name of the Small Flavor supported by the cloud provider
62
63   flavor_medium:
64     type: string
65     description: Name of the Medium Flavor supported by the cloud provider
66
67   flavor_large:
68     type: string
69     description: Name of the Large Flavor supported by the cloud provider
70
71   flavor_xlarge:
72     type: string
73     description: Name of the Extra Large Flavor supported by the cloud provider
74
75   flavor_xxlarge:
76     type: string
77     description: Name of the Extra Extra Large Flavor supported by the cloud provider
78
79   vm_base_name:
80     type: string
81     description: Base name of ONAP VMs
82
83   key_name:
84     type: string
85     description: Public/Private key pair name
86
87   pub_key:
88     type: string
89     description: Public key to be installed on the compute instance
90
91   nexus_repo:
92     type: string
93     description: Complete URL for the Nexus repository.
94
95   nexus_docker_repo:
96     type: string
97     description: Complete URL for the Nexus repository for docker images.
98
99   nexus_username:
100     type: string
101     description: Nexus Repository username
102
103   nexus_password:
104     type: string
105     description: Nexus Repository Password
106
107   artifacts_version:
108     type: string
109     description: Artifacts version of ONAP components
110
111   dmaap_topic:
112     type: string
113     description: DMaaP Topic name
114
115   openstack_tenant_id:
116     type: string
117     description: OpenStack tenant ID
118
119   openstack_tenant_name:
120     type: string
121     description: OpenStack tenant name (matching with the openstack_tenant_id)
122
123   openstack_username:
124     type: string
125     description: OpenStack username
126
127   openstack_auth_method:
128     type: string
129     description: OpenStack authentication method (password VS. api-key)
130
131   openstack_api_key:
132     type: string
133     description: OpenStack password or API Key
134
135   horizon_url:
136     type: string
137     description: URL of OpenStack Horizon
138
139   keystone_url:
140     type: string
141     description: URL of OpenStack Keystone
142
143   cloud_env:
144     type: string
145     description: Cloud Provider Name in lower case
146
147   openstack_region:
148     type: string
149     description: Region where the DCAE controller will spin the VMs
150
151   ######################
152   #                    #
153   # Network parameters #
154   #                    #
155   ######################
156
157   dns_list:
158     type: comma_delimited_list
159     description: List of External DNS for OAM ONAP network
160
161   external_dns:
162     type: string
163     description: Public IP of the external DNS for ONAP network
164
165   dns_forwarder:
166     type: string
167     description: the forwarder address for setting up ONAP's private DNS server
168
169   oam_network_cidr:
170     type: string
171     description: CIDR of the OAM ONAP network
172
173   ### Private IP addresses ###
174   aai1_ip_addr:
175     type: string
176   aai2_ip_addr:
177     type: string
178   appc_ip_addr:
179     type: string
180   dcae_ip_addr:
181     type: string
182   dns_ip_addr:
183     type: string
184   so_ip_addr:
185     type: string
186   mr_ip_addr:
187     type: string
188   policy_ip_addr:
189     type: string
190   portal_ip_addr:
191     type: string
192   robot_ip_addr:
193     type: string
194   sdc_ip_addr:
195     type: string
196   sdnc_ip_addr:
197     type: string
198   vid_ip_addr:
199     type: string
200   clamp_ip_addr:
201     type: string
202   openo_ip_addr:
203     type: string
204   music_ip_addr:
205     type: string
206   oof_ip_addr:
207     type: string
208   aaf_ip_addr:
209     type: string
210   nbi_ip_addr:
211     type: string
212
213   ###########################
214   #                         #
215   # Parameters used by DCAE #
216   #                         #
217   ###########################
218
219   dnsaas_config_enabled:
220     type: string
221     description: whether the DNSaaS configuration section is enabled
222
223   dnsaas_region:
224     type: string
225     description: the region of the cloud instance providing the Designate DNS as a Service
226
227   dnsaas_keystone_url:
228     type: string
229     description: the keystone URL of the cloud instance providing the Designate DNS as a Service
230
231   dnsaas_username:
232     type: string
233     description: the username of the cloud instance providing the Designate DNS as a Service
234
235   dnsaas_password:
236     type: string
237     description: the password of the cloud instance providing the Designate DNS as a Service
238
239   dnsaas_tenant_name:
240     type: string
241     description: the name of the tenant in the cloud instance providing the Designate DNS as a Service
242
243   dcae_keystone_url:
244     type: string
245     description: the keystone URL for DCAE to use (via MultiCloud)
246
247   dcae_private_key:
248     type: string
249     description: the private key of the key-apir used between the DCAE bootstrap container and DCAE VMs
250
251   dcae_public_key:
252     type: string
253     description: the prublic key of the key-apir used between the DCAE bootstrap container and DCAE VMs
254
255   dcae_centos_7_image:
256     type: string
257     description: the id/name of the CentOS 7 VM imange
258
259   dcae_domain:
260     type: string
261     description: the top level domain to register DCAE VMs (the zone will be random-str.dcae_domain)
262
263   #####################
264   #                   #
265   # ONAP repositories #
266   #                   #
267   #####################
268
269   aai_repo:
270     type: string
271   appc_repo:
272     type: string
273   mr_repo:
274     type: string
275   so_repo:
276     type: string
277   policy_repo:
278     type: string
279   portal_repo:
280     type: string
281   robot_repo:
282     type: string
283   sdc_repo:
284     type: string
285   sdnc_repo:
286     type: string
287   vid_repo:
288     type: string
289   clamp_repo:
290     type: string
291   vnfsdk_repo:
292     type: string
293   music_repo:
294     type: string
295   nbi_repo:
296     type: string
297   aaf_repo:
298     type: string
299   oof_repo:
300     type: string
301
302   ################################
303   #                              #
304   # Docker versions and branches #
305   #                              #
306   ################################
307
308   aai_docker:
309     type: string
310   aai_sparky_docker:
311     type: string
312   appc_docker:
313     type: string
314   so_docker:
315     type: string
316   dcae_docker:
317     type: string
318   policy_docker:
319     type: string
320   portal_docker:
321     type: string
322   robot_docker:
323     type: string
324   sdc_docker:
325     type: string
326   sdc_wfd_docker:
327     type: string
328   sdnc_docker:
329     type: string
330   vid_docker:
331     type: string
332   clamp_docker:
333     type: string
334   msb_docker:
335     type: string
336   mvim_docker:
337     type: string
338   uui_docker:
339     type: string
340   esr_docker:
341     type: string
342   dgbuilder_docker:
343     type: string
344   cli_docker:
345     type: string
346   music_docker:
347     type: string
348   oof_docker:
349     type: string
350   aaf_docker:
351     type: string
352   nbi_docker:
353     type: string
354
355   vfc_nokia_docker:
356     type: string
357   vfc_nokiav2_docker:
358     type: string
359   vfc_ztevnfmdriver_docker:
360     type: string
361   vfc_ztesdncdriver_docker:
362     type: string
363   vfc_vnfres_docker:
364     type: string
365   vfc_vnfmgr_docker:
366     type: string
367   vfc_vnflcm_docker:
368     type: string
369   vfc_resmanagement_docker:
370     type: string
371   vfc_nslcm_docker:
372     type: string
373   vfc_huawei_docker:
374     type: string
375   vfc_jujudriver_docker:
376     type: string
377   vfc_gvnfmdriver_docker:
378     type: string
379   vfc_emsdriver_docker:
380     type: string
381   vfc_catalog_docker:
382     type: string
383   vfc_wfengine_mgrservice_docker:
384     type: string
385   vfc_wfengine_activiti_docker:
386     type: string
387
388   cbam_username:
389     type: string
390   cbam_password:
391     type: string
392   cbam_ip:
393     type: string
394
395   aai_branch:
396     type: string
397   appc_branch:
398     type: string
399   so_branch:
400     type: string
401   mr_branch:
402     type: string
403   policy_branch:
404     type: string
405   portal_branch:
406     type: string
407   robot_branch:
408     type: string
409   sdc_branch:
410     type: string
411   sdnc_branch:
412     type: string
413   vid_branch:
414     type: string
415   clamp_branch:
416     type: string
417   vnfsdk_branch:
418     type: string
419   music_branch:
420     type: string
421   nbi_branch:
422     type: string
423   aaf_branch:
424     type: string
425   oof_branch:
426     type: string
427
428 #############
429 #           #
430 # RESOURCES #
431 #           #
432 #############
433
434 resources:
435   random-str:
436     type: OS::Heat::RandomString
437     properties:
438       length: 4
439
440   # Public key used to access ONAP components
441   vm_key:
442     type: OS::Nova::KeyPair
443     properties:
444       name:
445         str_replace:
446           template: base_rand
447           params:
448             base: { get_param: key_name }
449             rand: { get_resource: random-str }
450       public_key: { get_param: pub_key }
451       save_private_key: false
452
453
454   # ONAP security group
455   onap_sg:
456     type: OS::Neutron::SecurityGroup
457     properties:
458       name:
459         str_replace:
460           template: base_rand
461           params:
462             base: onap_sg
463             rand: { get_resource: random-str }
464       description: security group used by ONAP
465       rules:
466         # All egress traffic
467         - direction: egress
468           ethertype: IPv4
469         - direction: egress
470           ethertype: IPv6
471         # ingress traffic
472         # ICMP
473         - protocol: icmp
474         - protocol: udp
475           port_range_min: 1
476           port_range_max: 65535
477         - protocol: tcp
478           port_range_min: 1
479           port_range_max: 65535
480
481
482
483   # ONAP management private network
484   oam_onap:
485     type: OS::Neutron::Net
486     properties:
487       name:
488         str_replace:
489           template: oam_onap_rand
490           params:
491             rand: { get_resource: random-str }
492
493   oam_onap_subnet:
494     type: OS::Neutron::Subnet
495     properties:
496       name:
497         str_replace:
498           template: oam_onap_rand
499           params:
500             rand: { get_resource: random-str }
501       network_id: { get_resource: oam_onap }
502       cidr: { get_param: oam_network_cidr }
503       dns_nameservers: { get_param: dns_list }
504
505   router:
506     type: OS::Neutron::Router
507     properties:
508       external_gateway_info:
509         network: { get_param: public_net_id }
510
511   router_interface:
512     type: OS::Neutron::RouterInterface
513     properties:
514       router_id: { get_resource: router }
515       subnet_id: { get_resource: oam_onap_subnet }
516
517
518   # DNS Server instantiation
519   dns_private_port:
520     type: OS::Neutron::Port
521     properties:
522       network: { get_resource: oam_onap }
523       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: dns_ip_addr }}]
524       security_groups:
525       - { get_resource: onap_sg }
526
527   dns_floating_ip:
528     type: OS::Neutron::FloatingIP
529     properties:
530       floating_network_id: { get_param: public_net_id }
531       port_id: { get_resource: dns_private_port }
532
533   dns_vm:
534     type: OS::Nova::Server
535     properties:
536       image: { get_param: ubuntu_1404_image }
537       flavor: { get_param: flavor_small }
538       name:
539         str_replace:
540           template: base-dns-server
541           params:
542             base: { get_param: vm_base_name }
543       key_name: { get_resource: vm_key }
544       networks:
545         - port: { get_resource: dns_private_port }
546       user_data_format: RAW
547       user_data:
548         str_replace:
549           params:
550             __nexus_repo__: { get_param: nexus_repo }
551             __artifacts_version__: { get_param: artifacts_version }
552             __oam_network_cidr__: { get_attr: [oam_onap_subnet, cidr] }
553             __dns_ip_addr__: { get_param: dns_ip_addr }
554             __aai1_ip_addr__: { get_param: aai1_ip_addr }
555             __aai2_ip_addr__: { get_param: aai2_ip_addr }
556             __appc_ip_addr__: { get_param: appc_ip_addr }
557             __dcae_ip_addr__: { get_param: dcae_ip_addr }
558             __so_ip_addr__: { get_param: so_ip_addr }
559             __mr_ip_addr__: { get_param: mr_ip_addr }
560             __policy_ip_addr__: { get_param: policy_ip_addr }
561             __portal_ip_addr__: { get_param: portal_ip_addr }
562             __robot_ip_addr__: { get_param: robot_ip_addr }
563             __sdc_ip_addr__: { get_param: sdc_ip_addr }
564             __sdnc_ip_addr__: { get_param: sdnc_ip_addr }
565             __vid_ip_addr__: { get_param: vid_ip_addr }
566             __clamp_ip_addr__: { get_param: clamp_ip_addr }
567             __openo_ip_addr__: { get_param: openo_ip_addr }
568             __music_ip_addr__: { get_param: music_ip_addr }
569             __oof_ip_addr__: { get_param: oof_ip_addr }
570             __aaf_ip_addr__: { get_param: aaf_ip_addr }
571             __cloud_env__: { get_param: cloud_env }
572             __external_dns__: { get_param: external_dns }
573             __dns_forwarder__: { get_param: dns_forwarder }
574           template: |
575             #!/bin/bash
576
577             # Create configuration files
578             mkdir -p /opt/config
579             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
580             echo "__cloud_env__" > /opt/config/cloud_env.txt
581             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
582             echo "__oam_network_cidr__" > /opt/config/oam_network_cidr.txt
583             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
584             echo "__aai1_ip_addr__" > /opt/config/aai1_ip_addr.txt
585             echo "__aai2_ip_addr__" > /opt/config/aai2_ip_addr.txt
586             echo "__appc_ip_addr__" > /opt/config/appc_ip_addr.txt
587             echo "__dcae_ip_addr__" > /opt/config/dcae_ip_addr.txt
588             echo "__so_ip_addr__" > /opt/config/so_ip_addr.txt
589             echo "__mr_ip_addr__" > /opt/config/mr_ip_addr.txt
590             echo "__policy_ip_addr__" > /opt/config/policy_ip_addr.txt
591             echo "__portal_ip_addr__" > /opt/config/portal_ip_addr.txt
592             echo "__robot_ip_addr__" > /opt/config/robot_ip_addr.txt
593             echo "__sdc_ip_addr__" > /opt/config/sdc_ip_addr.txt
594             echo "__sdnc_ip_addr__" > /opt/config/sdnc_ip_addr.txt
595             echo "__vid_ip_addr__" > /opt/config/vid_ip_addr.txt
596             echo "__clamp_ip_addr__" > /opt/config/clamp_ip_addr.txt
597             echo "__openo_ip_addr__" > /opt/config/openo_ip_addr.txt
598             echo "__music_ip_addr__" > /opt/config/music_ip_addr.txt
599             echo "__oof_ip_addr__" > /opt/config/oof_ip_addr.txt
600             echo "__aaf_ip_addr__" > /opt/config/aaf_ip_addr.txt
601             echo "__external_dns__" > /opt/config/external_dns.txt
602             echo "__dns_forwarder__" > /opt/config/dns_forwarder.txt
603
604             # Download and run install script
605             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/dns_install.sh -o /opt/dns_install.sh
606             cd /opt
607             chmod +x dns_install.sh
608             ./dns_install.sh
609
610
611   # A&AI instantiation (2 VMs)
612   aai1_private_port:
613     type: OS::Neutron::Port
614     properties:
615       network: { get_resource: oam_onap }
616       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: aai1_ip_addr }}]
617       security_groups:
618       - { get_resource: onap_sg }
619
620   aai1_floating_ip:
621     type: OS::Neutron::FloatingIP
622     properties:
623       floating_network_id: { get_param: public_net_id }
624       port_id: { get_resource: aai1_private_port }
625
626   aai1_vm:
627     type: OS::Nova::Server
628     depends_on: aai2_vm
629     properties:
630       image: { get_param: ubuntu_1404_image }
631       flavor: { get_param: flavor_large }
632       name:
633         str_replace:
634           template: base-aai-inst1
635           params:
636             base: { get_param: vm_base_name }
637       key_name: { get_resource: vm_key }
638       networks:
639         - port: { get_resource: aai1_private_port }
640       user_data_format: RAW
641       user_data:
642         str_replace:
643           params:
644             __nexus_repo__: { get_param: nexus_repo }
645             __nexus_docker_repo__: { get_param: nexus_docker_repo }
646             __nexus_username__: { get_param: nexus_username }
647             __nexus_password__: { get_param: nexus_password }
648             __dmaap_topic__: { get_param: dmaap_topic }
649             __artifacts_version__: { get_param: artifacts_version }
650             __dns_ip_addr__: { get_param: dns_ip_addr }
651             __docker_version__: { get_param: aai_docker }
652             __aai_sparky_docker__ : { get_param: aai_sparky_docker }
653             __gerrit_branch__: { get_param: aai_branch }
654             __cloud_env__: { get_param: cloud_env }
655             __external_dns__: { get_param: external_dns }
656             __aai_repo__: { get_param: aai_repo }
657           template: |
658             #!/bin/bash
659
660             # Create configuration files
661             mkdir -p /opt/config
662             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
663             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
664             echo "__nexus_username__" > /opt/config/nexus_username.txt
665             echo "__nexus_password__" > /opt/config/nexus_password.txt
666             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
667             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
668             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
669             echo "__docker_version__" > /opt/config/docker_version.txt
670             echo "__aai_sparky_docker__" > /opt/config/sparky_version.txt
671             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
672             echo "aai_instance_1" > /opt/config/aai_instance.txt
673             echo "__cloud_env__" > /opt/config/cloud_env.txt
674             echo "__external_dns__" > /opt/config/external_dns.txt
675             echo "__aai_repo__" > /opt/config/remote_repo.txt
676
677             # Download and run install script
678             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/aai_install.sh -o /opt/aai_install.sh
679             cd /opt
680             chmod +x aai_install.sh
681             ./aai_install.sh
682
683
684   aai2_private_port:
685     type: OS::Neutron::Port
686     properties:
687       network: { get_resource: oam_onap }
688       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: aai2_ip_addr }}]
689       security_groups:
690       - { get_resource: onap_sg }
691
692   aai2_floating_ip:
693     type: OS::Neutron::FloatingIP
694     properties:
695       floating_network_id: { get_param: public_net_id }
696       port_id: { get_resource: aai2_private_port }
697
698   aai2_vm:
699     type: OS::Nova::Server
700     properties:
701       image: { get_param: ubuntu_1404_image }
702       flavor: { get_param: flavor_large }
703       name:
704         str_replace:
705           template: base-aai-inst2
706           params:
707             base: { get_param: vm_base_name }
708       key_name: { get_resource: vm_key }
709       networks:
710         - port: { get_resource: aai2_private_port }
711       user_data_format: RAW
712       user_data:
713         str_replace:
714           params:
715             __nexus_repo__: { get_param: nexus_repo }
716             __nexus_docker_repo__: { get_param: nexus_docker_repo }
717             __nexus_username__: { get_param: nexus_username }
718             __nexus_password__: { get_param: nexus_password }
719             __dmaap_topic__: { get_param: dmaap_topic }
720             __artifacts_version__: { get_param: artifacts_version }
721             __dns_ip_addr__: { get_param: dns_ip_addr }
722             __docker_version__: { get_param: aai_docker }
723             __gerrit_branch__: { get_param: aai_branch }
724             __cloud_env__: { get_param: cloud_env }
725             __external_dns__: { get_param: external_dns }
726             __aai_repo__: { get_param: aai_repo }
727           template: |
728             #!/bin/bash
729
730             # Create configuration files
731             mkdir -p /opt/config
732             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
733             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
734             echo "__nexus_username__" > /opt/config/nexus_username.txt
735             echo "__nexus_password__" > /opt/config/nexus_password.txt
736             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
737             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
738             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
739             echo "__docker_version__" > /opt/config/docker_version.txt
740             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
741             echo "aai_instance_2" > /opt/config/aai_instance.txt
742             echo "__cloud_env__" > /opt/config/cloud_env.txt
743             echo "__external_dns__" > /opt/config/external_dns.txt
744             echo "__aai_repo__" > /opt/config/remote_repo.txt
745
746             # Download and run install script
747             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/aai_install.sh -o /opt/aai_install.sh
748             cd /opt
749             chmod +x aai_install.sh
750             ./aai_install.sh
751
752
753   # SO instantiation
754   so_private_port:
755     type: OS::Neutron::Port
756     properties:
757       network: { get_resource: oam_onap }
758       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: so_ip_addr }}]
759       security_groups:
760       - { get_resource: onap_sg }
761
762   so_floating_ip:
763     type: OS::Neutron::FloatingIP
764     properties:
765       floating_network_id: { get_param: public_net_id }
766       port_id: { get_resource: so_private_port }
767
768   so_vm:
769     type: OS::Nova::Server
770     properties:
771       image: { get_param: ubuntu_1604_image }
772       flavor: { get_param: flavor_medium }
773       name:
774         str_replace:
775           template: base-so
776           params:
777             base: { get_param: vm_base_name }
778       key_name: { get_resource: vm_key }
779       networks:
780         - port: { get_resource: so_private_port }
781       user_data_format: RAW
782       user_data:
783         str_replace:
784           params:
785             __nexus_repo__: { get_param: nexus_repo }
786             __nexus_docker_repo__: { get_param: nexus_docker_repo }
787             __nexus_username__: { get_param: nexus_username }
788             __nexus_password__: { get_param: nexus_password }
789             __openstack_username__: { get_param: openstack_username }
790             __openstack_tenant_id__: { get_param: openstack_tenant_id }
791             __openstack_api_key__: { get_param: openstack_api_key }
792             __openstack_region__: { get_param: openstack_region }
793             __keystone_url__: { get_param: keystone_url }
794             __dmaap_topic__: { get_param: dmaap_topic }
795             __artifacts_version__: { get_param: artifacts_version }
796             __dns_ip_addr__: { get_param: dns_ip_addr }
797             __openo_ip__: { get_param: openo_ip_addr }
798             __docker_version__: { get_param: so_docker }
799             __gerrit_branch__: { get_param: so_branch }
800             __cloud_env__: { get_param: cloud_env }
801             __external_dns__: { get_param: external_dns }
802             __so_repo__: { get_param: so_repo }
803           template: |
804             #!/bin/bash
805
806             # Create configuration files
807             mkdir -p /opt/config
808             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
809             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
810             echo "__nexus_username__" > /opt/config/nexus_username.txt
811             echo "__nexus_password__" > /opt/config/nexus_password.txt
812             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
813             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
814             echo "__openo_ip__" > /opt/config/openo_ip.txt
815             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
816             echo "__openstack_username__" > /opt/config/openstack_username.txt
817             echo "__openstack_tenant_id__" > /opt/config/tenant_id.txt
818             echo "__openstack_api_key__" > /opt/config/openstack_api_key.txt
819             echo "__openstack_region__" > /opt/config/openstack_region.txt
820             echo "__keystone_url__" > /opt/config/keystone.txt
821             echo "__docker_version__" > /opt/config/docker_version.txt
822             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
823             echo "__cloud_env__" > /opt/config/cloud_env.txt
824             echo "__external_dns__" > /opt/config/external_dns.txt
825             echo "__so_repo__" > /opt/config/remote_repo.txt
826
827             # Download and run install script
828             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/so_install.sh -o /opt/so_install.sh
829             cd /opt
830             chmod +x so_install.sh
831             ./so_install.sh
832
833
834   # Message Router instantiation
835   mrouter_private_port:
836     type: OS::Neutron::Port
837     properties:
838       network: { get_resource: oam_onap }
839       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: mr_ip_addr }}]
840       security_groups:
841       - { get_resource: onap_sg }
842
843   mrouter_floating_ip:
844     type: OS::Neutron::FloatingIP
845     properties:
846       floating_network_id: { get_param: public_net_id }
847       port_id: { get_resource: mrouter_private_port }
848
849   mrouter_vm:
850     type: OS::Nova::Server
851     properties:
852       image: { get_param: ubuntu_1404_image }
853       flavor: { get_param: flavor_medium }
854       name:
855         str_replace:
856           template: base-message-router
857           params:
858             base: { get_param: vm_base_name }
859       key_name: { get_resource: vm_key }
860       networks:
861         - port: { get_resource: mrouter_private_port }
862       user_data_format: RAW
863       user_data:
864         str_replace:
865           params:
866             __nexus_repo__: { get_param: nexus_repo }
867             __nexus_docker_repo__: { get_param: nexus_docker_repo }
868             __nexus_username__: { get_param: nexus_username }
869             __nexus_password__: { get_param: nexus_password }
870             __artifacts_version__: { get_param: artifacts_version }
871             __dns_ip_addr__: { get_param: dns_ip_addr }
872             __gerrit_branch__: { get_param: mr_branch }
873             __cloud_env__: { get_param: cloud_env }
874             __external_dns__: { get_param: external_dns }
875             __mr_repo__: { get_param: mr_repo }
876           template: |
877             #!/bin/bash
878
879             # Create configuration files
880             mkdir -p /opt/config
881             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
882             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
883             echo "__nexus_username__" > /opt/config/nexus_username.txt
884             echo "__nexus_password__" > /opt/config/nexus_password.txt
885             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
886             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
887             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
888             echo "__cloud_env__" > /opt/config/cloud_env.txt
889             echo "__external_dns__" > /opt/config/external_dns.txt
890             echo "__mr_repo__" > /opt/config/remote_repo.txt
891
892             # Download and run install script
893             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/mr_install.sh -o /opt/mr_install.sh
894             cd /opt
895             chmod +x mr_install.sh
896             ./mr_install.sh
897
898
899   # Robot Framework instantiation
900   robot_private_port:
901     type: OS::Neutron::Port
902     properties:
903       network: { get_resource: oam_onap }
904       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: robot_ip_addr }}]
905       security_groups:
906       - { get_resource: onap_sg }
907
908   robot_floating_ip:
909     type: OS::Neutron::FloatingIP
910     properties:
911       floating_network_id: { get_param: public_net_id }
912       port_id: { get_resource: robot_private_port }
913
914   robot_vm:
915     type: OS::Nova::Server
916     properties:
917       image: { get_param: ubuntu_1604_image }
918       flavor: { get_param: flavor_small }
919       name:
920         str_replace:
921           template: base-robot
922           params:
923             base: { get_param: vm_base_name }
924       key_name: { get_resource: vm_key }
925       networks:
926         - port: { get_resource: robot_private_port }
927       user_data_format: RAW
928       user_data:
929         str_replace:
930           params:
931             __nexus_repo__: { get_param: nexus_repo }
932             __nexus_docker_repo__: { get_param: nexus_docker_repo }
933             __nexus_username__: { get_param: nexus_username }
934             __nexus_password__: { get_param: nexus_password }
935             __network_name__: { get_attr: [oam_onap, name] }
936             __openstack_username__: { get_param: openstack_username }
937             __openstack_api_key__: { get_param : openstack_api_key }
938             __openstack_tenant_id__: { get_param: openstack_tenant_id }
939             __artifacts_version__: { get_param: artifacts_version }
940             __openstack_region__: { get_param: openstack_region }
941             __dns_ip_addr__: { get_param: dns_ip_addr }
942             __gerrit_branch__: { get_param: robot_branch }
943             __cloud_env__: { get_param: cloud_env }
944             __keystone_url__: { get_param: keystone_url }
945             __aai1_ip_addr__: { get_param: aai1_ip_addr }
946             __aai2_ip_addr__: { get_param: aai2_ip_addr }
947             __appc_ip_addr__: { get_param: appc_ip_addr }
948             __dcae_ip_addr__: { get_param: dcae_ip_addr }
949             __so_ip_addr__: { get_param: so_ip_addr }
950             __mr_ip_addr__: { get_param: mr_ip_addr }
951             __policy_ip_addr__: { get_param: policy_ip_addr }
952             __portal_ip_addr__: { get_param: portal_ip_addr }
953             __sdc_ip_addr__: { get_param: sdc_ip_addr }
954             __sdnc_ip_addr__: { get_param: sdnc_ip_addr }
955             __vid_ip_addr__: { get_param: vid_ip_addr }
956             __clamp_ip_addr__: { get_param: clamp_ip_addr }
957             __openo_ip_addr__: { get_param: openo_ip_addr }
958             __clamp_ip_addr__: { get_param: clamp_ip_addr }
959             __openo_ip_addr__: { get_param: openo_ip_addr }
960             __music_ip_addr__: { get_param: music_ip_addr }
961             __nbi_ip_addr__: { get_param: nbi_ip_addr }
962             __external_dns__: { get_param: external_dns }
963             __vm_image_name__: { get_param: ubuntu_1404_image }
964             __vm_flavor__: { get_param: flavor_medium }
965             __public_net_id__: { get_param: public_net_id }
966             __script_version__: { get_param: artifacts_version }
967             __robot_repo__: { get_param: robot_repo }
968             __docker_version__: { get_param: robot_docker }
969           template: |
970             #!/bin/bash
971
972             # Create configuration files
973             mkdir -p /opt/config
974             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
975             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
976             echo "__nexus_username__" > /opt/config/nexus_username.txt
977             echo "__nexus_password__" > /opt/config/nexus_password.txt
978             echo "__network_name__" > /opt/config/network.txt
979             echo "__openstack_username__" > /opt/config/openstack_username.txt
980             echo "__openstack_api_key__" > /opt/config/openstack_password.txt
981             echo "__openstack_tenant_id__" > /opt/config/openstack_tenant_id.txt
982             echo "__openstack_region__" > /opt/config/region.txt
983             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
984             echo "__docker_version__" > /opt/config/docker_version.txt
985             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
986             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
987             echo "__keystone_url__" > /opt/config/keystone.txt
988             echo "__aai1_ip_addr__" > /opt/config/aai1_ip_addr.txt
989             echo "__aai2_ip_addr__" > /opt/config/aai2_ip_addr.txt
990             echo "__appc_ip_addr__" > /opt/config/appc_ip_addr.txt
991             echo "__dcae_ip_addr__" > /opt/config/dcae_ip_addr.txt
992             echo "__so_ip_addr__" > /opt/config/so_ip_addr.txt
993             echo "__mr_ip_addr__" > /opt/config/mr_ip_addr.txt
994             echo "__policy_ip_addr__" > /opt/config/policy_ip_addr.txt
995             echo "__portal_ip_addr__" > /opt/config/portal_ip_addr.txt
996             echo "__portal_ip_addr__" > /opt/config/cli_ip_addr.txt
997             echo "__sdc_ip_addr__" > /opt/config/sdc_ip_addr.txt
998             echo "__sdc_ip_addr__" > /opt/config/sdc_be_ip_addr.txt
999             echo "__sdc_ip_addr__" > /opt/config/sdc_fe_ip_addr.txt
1000             echo "__sdnc_ip_addr__" > /opt/config/sdnc_ip_addr.txt
1001             echo "__vid_ip_addr__" > /opt/config/vid_ip_addr.txt
1002             echo "__clamp_ip_addr__" > /opt/config/clamp_ip_addr.txt
1003             echo "__openo_ip_addr__" > /opt/config/openo_ip_addr.txt
1004             echo "__music_ip_addr__" > /opt/config/music_ip_addr.txt
1005             echo "__nbi_ip_addr__" > /opt/config/nbi_ip_addr.txt
1006             echo "__oof_ip_addr__" > /opt/config/oof_ip_addr.txt
1007             echo "__aaf_ip_addr__" > /opt/config/aaf_ip_addr.txt
1008             echo "__cloud_env__" > /opt/config/cloud_env.txt
1009             echo "__external_dns__" > /opt/config/external_dns.txt
1010             echo "__vm_image_name__" > /opt/config/vm_image_name.txt
1011             echo "__ubuntu_1404_image__" > /opt/config/ubuntu_1404_image.txt
1012             echo "__ubuntu_1604_image__" > /opt/config/ubuntu_1604_image.txt
1013             echo "__script_version__" > /opt/config/script_version.txt
1014             echo "__public_net_id__" > /opt/config/public_net_id.txt
1015             echo "__robot_repo__" > /opt/config/remote_repo.txt
1016
1017             # Download and run install script
1018             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/robot_install.sh -o /opt/robot_install.sh
1019             cd /opt
1020             chmod +x robot_install.sh
1021             ./robot_install.sh
1022
1023
1024   # VID instantiation
1025   vid_private_port:
1026     type: OS::Neutron::Port
1027     properties:
1028       network: { get_resource: oam_onap }
1029       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: vid_ip_addr }}]
1030       security_groups:
1031       - { get_resource: onap_sg }
1032
1033   vid_floating_ip:
1034     type: OS::Neutron::FloatingIP
1035     properties:
1036       floating_network_id: { get_param: public_net_id }
1037       port_id: { get_resource: vid_private_port }
1038
1039   vid_vm:
1040     type: OS::Nova::Server
1041     properties:
1042       image: { get_param: ubuntu_1404_image }
1043       flavor: { get_param: flavor_medium }
1044       name:
1045         str_replace:
1046           template: base-vid
1047           params:
1048             base: { get_param: vm_base_name }
1049       key_name: { get_resource: vm_key }
1050       networks:
1051         - port: { get_resource: vid_private_port }
1052       user_data_format: RAW
1053       user_data:
1054         str_replace:
1055           params:
1056             __nexus_repo__: { get_param: nexus_repo }
1057             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1058             __nexus_username__: { get_param: nexus_username }
1059             __nexus_password__: { get_param: nexus_password }
1060             __artifacts_version__: { get_param: artifacts_version }
1061             __dns_ip_addr__: { get_param: dns_ip_addr }
1062             __docker_version__: { get_param: vid_docker }
1063             __gerrit_branch__: { get_param: vid_branch }
1064             __cloud_env__: { get_param: cloud_env }
1065             __external_dns__: { get_param: external_dns }
1066             __vid_repo__: { get_param: vid_repo }
1067           template: |
1068             #!/bin/bash
1069
1070             # Create configuration files
1071             mkdir -p /opt/config
1072             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1073             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1074             echo "__nexus_username__" > /opt/config/nexus_username.txt
1075             echo "__nexus_password__" > /opt/config/nexus_password.txt
1076             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1077             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1078             echo "__docker_version__" > /opt/config/docker_version.txt
1079             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1080             echo "__cloud_env__" > /opt/config/cloud_env.txt
1081             echo "__external_dns__" > /opt/config/external_dns.txt
1082             echo "__vid_repo__" > /opt/config/remote_repo.txt
1083
1084             # Download and run install script
1085             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/vid_install.sh -o /opt/vid_install.sh
1086             cd /opt
1087             chmod +x vid_install.sh
1088             ./vid_install.sh
1089
1090
1091   # SDN-C instantiation
1092   sdnc_private_port:
1093     type: OS::Neutron::Port
1094     properties:
1095       network: { get_resource: oam_onap }
1096       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: sdnc_ip_addr }}]
1097       security_groups:
1098       - { get_resource: onap_sg }
1099
1100   sdnc_floating_ip:
1101     type: OS::Neutron::FloatingIP
1102     properties:
1103       floating_network_id: { get_param: public_net_id }
1104       port_id: { get_resource: sdnc_private_port }
1105
1106   sdnc_vm:
1107     type: OS::Nova::Server
1108     properties:
1109       image: { get_param: ubuntu_1404_image }
1110       flavor: { get_param: flavor_medium }
1111       name:
1112         str_replace:
1113           template: base-sdnc
1114           params:
1115             base: { get_param: vm_base_name }
1116       key_name: { get_resource: vm_key }
1117       networks:
1118         - port: { get_resource: sdnc_private_port }
1119       user_data_format: RAW
1120       user_data:
1121         str_replace:
1122           params:
1123             __nexus_repo__: { get_param: nexus_repo }
1124             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1125             __nexus_username__: { get_param: nexus_username }
1126             __nexus_password__: { get_param: nexus_password }
1127             __artifacts_version__: { get_param: artifacts_version }
1128             __dns_ip_addr__: { get_param: dns_ip_addr }
1129             __docker_version__: { get_param: sdnc_docker }
1130             __gerrit_branch__: { get_param: sdnc_branch }
1131             __dgbuilder_docker__: { get_param: dgbuilder_docker }
1132             __cloud_env__: { get_param: cloud_env }
1133             __external_dns__: { get_param: external_dns }
1134             __sdnc_repo__: { get_param: sdnc_repo }
1135           template: |
1136             #!/bin/bash
1137
1138             # Create configuration files
1139             mkdir -p /opt/config
1140             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1141             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1142             echo "__nexus_username__" > /opt/config/nexus_username.txt
1143             echo "__nexus_password__" > /opt/config/nexus_password.txt
1144             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1145             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1146             echo "__docker_version__" > /opt/config/docker_version.txt
1147             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1148             echo "__dgbuilder_docker__" > /opt/config/dgbuilder_version.txt
1149             echo "__cloud_env__" > /opt/config/cloud_env.txt
1150             echo "__external_dns__" > /opt/config/external_dns.txt
1151             echo "__sdnc_repo__" > /opt/config/remote_repo.txt
1152
1153             # Download and run install script
1154             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/sdnc_install.sh -o /opt/sdnc_install.sh
1155             cd /opt
1156             chmod +x sdnc_install.sh
1157             ./sdnc_install.sh
1158
1159
1160   # SDC instantiation
1161   sdc_private_port:
1162     type: OS::Neutron::Port
1163     properties:
1164       network: { get_resource: oam_onap }
1165       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: sdc_ip_addr }}]
1166       security_groups:
1167       - { get_resource: onap_sg }
1168
1169   sdc_floating_ip:
1170     type: OS::Neutron::FloatingIP
1171     properties:
1172       floating_network_id: { get_param: public_net_id }
1173       port_id: { get_resource: sdc_private_port }
1174
1175   sdc_volume_data:
1176     type: OS::Cinder::Volume
1177     properties:
1178       name: vol1-sdc-data
1179       size: 100
1180
1181   sdc_vm:
1182     type: OS::Nova::Server
1183     properties:
1184       image: { get_param: ubuntu_1604_image }
1185       flavor: { get_param: flavor_large }
1186       name:
1187         str_replace:
1188           template: base-sdc
1189           params:
1190             base: { get_param: vm_base_name }
1191       key_name: { get_resource: vm_key }
1192       networks:
1193         - port: { get_resource: sdc_private_port }
1194       block_device_mapping:
1195         - device_name: /dev/vdb
1196           volume_id: {get_resource: sdc_volume_data}
1197       user_data_format: RAW
1198       user_data:
1199         str_replace:
1200           params:
1201             __nexus_repo__: { get_param: nexus_repo }
1202             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1203             __nexus_username__: { get_param: nexus_username }
1204             __nexus_password__: { get_param: nexus_password }
1205             __env_name__: { get_param: dmaap_topic }
1206             __artifacts_version__: { get_param: artifacts_version }
1207             __dns_ip_addr__: { get_param: dns_ip_addr }
1208             __mr_ip_addr__: { get_param: mr_ip_addr }
1209             __private_ip__: { get_param: sdc_ip_addr }
1210             __docker_version__: { get_param: sdc_docker }
1211             __sdc_wfd_docker__: { get_param: sdc_wfd_docker }
1212             __gerrit_branch__: { get_param: sdc_branch }
1213             __cloud_env__: { get_param: cloud_env }
1214             __external_dns__: { get_param: external_dns }
1215             __sdc_repo__: { get_param: sdc_repo }
1216           template: |
1217             #!/bin/bash
1218
1219             # Create configuration files
1220             mkdir -p /opt/config
1221             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1222             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1223             echo "__nexus_username__" > /opt/config/nexus_username.txt
1224             echo "__nexus_password__" > /opt/config/nexus_password.txt
1225             echo "__env_name__" > /opt/config/env_name.txt
1226             echo "__mr_ip_addr__" > /opt/config/mr_ip_addr.txt
1227             echo "__private_ip__" > /opt/config/private_ip.txt
1228             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1229             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1230             echo "__docker_version__" > /opt/config/docker_version.txt
1231             echo "__sdc_wfd_docker__" > /opt/config/sdc_wfd_docker.txt
1232             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1233             echo "__cloud_env__" > /opt/config/cloud_env.txt
1234             echo "__external_dns__" > /opt/config/external_dns.txt
1235             echo "__sdc_repo__" > /opt/config/remote_repo.txt
1236
1237             # Download and run install script
1238             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/sdc_install.sh -o /opt/sdc_install.sh
1239             cd /opt
1240             chmod +x sdc_install.sh
1241             ./sdc_install.sh
1242
1243
1244   # PORTAL instantiation
1245   portal_private_port:
1246     type: OS::Neutron::Port
1247     properties:
1248       network: { get_resource: oam_onap }
1249       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: portal_ip_addr }}]
1250       security_groups:
1251       - { get_resource: onap_sg }
1252
1253   portal_floating_ip:
1254     type: OS::Neutron::FloatingIP
1255     properties:
1256       floating_network_id: { get_param: public_net_id }
1257       port_id: { get_resource: portal_private_port }
1258
1259   portal_vm:
1260     type: OS::Nova::Server
1261     properties:
1262       image: { get_param: ubuntu_1404_image }
1263       flavor: { get_param: flavor_medium }
1264       name:
1265         str_replace:
1266           template: base-portal
1267           params:
1268             base: { get_param: vm_base_name }
1269       key_name: { get_resource: vm_key }
1270       networks:
1271         - port: { get_resource: portal_private_port }
1272       user_data_format: RAW
1273       user_data:
1274         str_replace:
1275           params:
1276             __nexus_repo__: { get_param: nexus_repo }
1277             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1278             __nexus_username__: { get_param: nexus_username }
1279             __nexus_password__: { get_param: nexus_password }
1280             __artifacts_version__: { get_param: artifacts_version }
1281             __dns_ip_addr__: { get_param: dns_ip_addr }
1282             __public_ip__: { get_attr: [portal_floating_ip, floating_ip_address] }
1283             __docker_version__: { get_param: portal_docker }
1284             __gerrit_branch__: { get_param: portal_branch }
1285             __cli_docker__: { get_param: cli_docker }
1286             __cloud_env__: { get_param: cloud_env }
1287             __external_dns__: { get_param: external_dns }
1288             __portal_repo__: { get_param: portal_repo }
1289           template: |
1290             #!/bin/bash
1291
1292             # Create configuration files
1293             mkdir -p /opt/config
1294             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1295             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1296             echo "__nexus_username__" > /opt/config/nexus_username.txt
1297             echo "__nexus_password__" > /opt/config/nexus_password.txt
1298             echo "__public_ip__" > /opt/config/public_ip.txt
1299             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1300             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1301             echo "__docker_version__" > /opt/config/docker_version.txt
1302             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1303             echo "__cli_docker__" > /opt/config/cli_docker_version.txt
1304             echo "__cloud_env__" > /opt/config/cloud_env.txt
1305             echo "__external_dns__" > /opt/config/external_dns.txt
1306             echo "__portal_repo__" > /opt/config/remote_repo.txt
1307
1308             # Download and run install script
1309             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/portal_install.sh -o /opt/portal_install.sh
1310             cd /opt
1311             chmod +x portal_install.sh
1312             ./portal_install.sh
1313
1314
1315   # Policy Engine instantiation
1316   policy_private_port:
1317     type: OS::Neutron::Port
1318     properties:
1319       network: { get_resource: oam_onap }
1320       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: policy_ip_addr }}]
1321       security_groups:
1322       - { get_resource: onap_sg }
1323
1324   policy_floating_ip:
1325     type: OS::Neutron::FloatingIP
1326     properties:
1327       floating_network_id: { get_param: public_net_id }
1328       port_id: { get_resource: policy_private_port }
1329
1330   policy_vm:
1331     type: OS::Nova::Server
1332     properties:
1333       image: { get_param: ubuntu_1404_image }
1334       flavor: { get_param: flavor_medium }
1335       name:
1336         str_replace:
1337           template: base-policy
1338           params:
1339             base: { get_param: vm_base_name }
1340       key_name: { get_resource: vm_key }
1341       networks:
1342         - port: { get_resource: policy_private_port }
1343       user_data_format: RAW
1344       user_data:
1345         str_replace:
1346           params:
1347             __nexus_repo__: { get_param: nexus_repo }
1348             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1349             __nexus_username__: { get_param: nexus_username }
1350             __nexus_password__: { get_param: nexus_password }
1351             __artifacts_version__: { get_param: artifacts_version }
1352             __dns_ip_addr__: { get_param: dns_ip_addr }
1353             __public_ip__: { get_attr: [policy_floating_ip, floating_ip_address] }
1354             __docker_version__: { get_param: policy_docker }
1355             __gerrit_branch__: { get_param: policy_branch }
1356             __cloud_env__: { get_param: cloud_env }
1357             __external_dns__: { get_param: external_dns }
1358             __policy_repo__: { get_param: policy_repo }
1359           template: |
1360             #!/bin/bash
1361
1362             # Create configuration files
1363             mkdir -p /opt/config
1364             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1365             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1366             echo "__nexus_username__" > /opt/config/nexus_username.txt
1367             echo "__nexus_password__" > /opt/config/nexus_password.txt
1368             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1369             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1370             echo "__public_ip__" > /opt/config/public_ip.txt
1371             echo "__docker_version__" > /opt/config/docker_version.txt
1372             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1373             echo "__cloud_env__" > /opt/config/cloud_env.txt
1374             echo "__external_dns__" > /opt/config/external_dns.txt
1375             echo "__policy_repo__" > /opt/config/remote_repo.txt
1376
1377             # Download and run install script
1378             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/policy_install.sh -o /opt/policy_install.sh
1379             cd /opt
1380             chmod +x policy_install.sh
1381             ./policy_install.sh
1382
1383
1384   # APP-C instantiation
1385   appc_private_port:
1386     type: OS::Neutron::Port
1387     properties:
1388       network: { get_resource: oam_onap }
1389       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: appc_ip_addr }}]
1390       security_groups:
1391       - { get_resource: onap_sg }
1392
1393   appc_floating_ip:
1394     type: OS::Neutron::FloatingIP
1395     properties:
1396       floating_network_id: { get_param: public_net_id }
1397       port_id: { get_resource: appc_private_port }
1398
1399   appc_vm:
1400     type: OS::Nova::Server
1401     properties:
1402       image: { get_param: ubuntu_1404_image }
1403       flavor: { get_param: flavor_medium }
1404       name:
1405         str_replace:
1406           template: base-appc
1407           params:
1408             base: { get_param: vm_base_name }
1409       key_name: { get_resource: vm_key }
1410       networks:
1411         - port: { get_resource: appc_private_port }
1412       user_data_format: RAW
1413       user_data:
1414         str_replace:
1415           params:
1416             __nexus_repo__: { get_param: nexus_repo }
1417             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1418             __nexus_username__: { get_param: nexus_username }
1419             __nexus_password__: { get_param: nexus_password }
1420             __dmaap_topic__: { get_param: dmaap_topic }
1421             __artifacts_version__: { get_param: artifacts_version }
1422             __dns_ip_addr__: { get_param: dns_ip_addr }
1423             __docker_version__: { get_param: appc_docker }
1424             __gerrit_branch__: { get_param: appc_branch }
1425             __dgbuilder_docker__: { get_param: dgbuilder_docker }
1426             __cloud_env__: { get_param: cloud_env }
1427             __external_dns__: { get_param: external_dns }
1428             __appc_repo__: { get_param: appc_repo }
1429           template: |
1430             #!/bin/bash
1431
1432             # Create configuration files
1433             mkdir -p /opt/config
1434             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1435             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1436             echo "__nexus_username__" > /opt/config/nexus_username.txt
1437             echo "__nexus_password__" > /opt/config/nexus_password.txt
1438             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1439             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1440             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
1441             echo "__docker_version__" > /opt/config/docker_version.txt
1442             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1443             echo "__dgbuilder_docker__" > /opt/config/dgbuilder_version.txt
1444             echo "__cloud_env__" > /opt/config/cloud_env.txt
1445             echo "__external_dns__" > /opt/config/external_dns.txt
1446             echo "__appc_repo__" > /opt/config/remote_repo.txt
1447
1448             # Download and run install script
1449             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/appc_install.sh -o /opt/appc_install.sh
1450             cd /opt
1451             chmod +x appc_install.sh
1452             ./appc_install.sh
1453
1454
1455   # CLAMP instantiation
1456   clamp_private_port:
1457     type: OS::Neutron::Port
1458     properties:
1459       network: { get_resource: oam_onap }
1460       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: clamp_ip_addr }}]
1461       security_groups:
1462       - { get_resource: onap_sg }
1463
1464   clamp_floating_ip:
1465     type: OS::Neutron::FloatingIP
1466     properties:
1467       floating_network_id: { get_param: public_net_id }
1468       port_id: { get_resource: clamp_private_port }
1469
1470   clamp_vm:
1471     type: OS::Nova::Server
1472     properties:
1473       image: { get_param: ubuntu_1604_image }
1474       flavor: { get_param: flavor_medium }
1475       name:
1476         str_replace:
1477           template: base-clamp
1478           params:
1479             base: { get_param: vm_base_name }
1480       key_name: { get_resource: vm_key }
1481       networks:
1482         - port: { get_resource: clamp_private_port }
1483       user_data_format: RAW
1484       user_data:
1485         str_replace:
1486           params:
1487             __nexus_repo__: { get_param: nexus_repo }
1488             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1489             __nexus_username__: { get_param: nexus_username }
1490             __nexus_password__: { get_param: nexus_password }
1491             __openstack_username__: { get_param: openstack_username }
1492             __openstack_tenant_id__: { get_param: openstack_tenant_id }
1493             __openstack_api_key__: { get_param: openstack_api_key }
1494             __openstack_region__: { get_param: openstack_region }
1495             __keystone_url__: { get_param: keystone_url }
1496             __dmaap_topic__: { get_param: dmaap_topic }
1497             __artifacts_version__: { get_param: artifacts_version }
1498             __dns_ip_addr__: { get_param: dns_ip_addr }
1499             __docker_version__: { get_param: clamp_docker }
1500             __gerrit_branch__: { get_param: clamp_branch }
1501             __cloud_env__: { get_param: cloud_env }
1502             __external_dns__: { get_param: external_dns }
1503             __clamp_repo__: { get_param: clamp_repo }
1504           template: |
1505             #!/bin/bash
1506
1507             # Create configuration files
1508             mkdir -p /opt/config
1509             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1510             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1511             echo "__nexus_username__" > /opt/config/nexus_username.txt
1512             echo "__nexus_password__" > /opt/config/nexus_password.txt
1513             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1514             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1515             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
1516             echo "__openstack_username__" > /opt/config/openstack_username.txt
1517             echo "__openstack_tenant_id__" > /opt/config/tenant_id.txt
1518             echo "__openstack_api_key__" > /opt/config/openstack_api_key.txt
1519             echo "__openstack_region__" > /opt/config/openstack_region.txt
1520             echo "__keystone_url__" > /opt/config/keystone.txt
1521             echo "__docker_version__" > /opt/config/docker_version.txt
1522             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1523             echo "__cloud_env__" > /opt/config/cloud_env.txt
1524             echo "__external_dns__" > /opt/config/external_dns.txt
1525             echo "__clamp_repo__" > /opt/config/remote_repo.txt
1526
1527             # Download and run install script
1528             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/clamp_install.sh -o /opt/clamp_install.sh
1529             cd /opt
1530             chmod +x clamp_install.sh
1531             ./clamp_install.sh
1532
1533
1534   # OPEN-O VM instantiation
1535   openo_private_port:
1536     type: OS::Neutron::Port
1537     properties:
1538       network: { get_resource: oam_onap }
1539       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: openo_ip_addr }}]
1540       security_groups:
1541       - { get_resource: onap_sg }
1542
1543   openo_floating_ip:
1544     type: OS::Neutron::FloatingIP
1545     properties:
1546       floating_network_id: { get_param: public_net_id }
1547       port_id: { get_resource: openo_private_port }
1548
1549   openo_vm:
1550     type: OS::Nova::Server
1551     properties:
1552       image: { get_param: ubuntu_1604_image }
1553       flavor: { get_param: flavor_large }
1554       name:
1555         str_replace:
1556           template: base-multi-service
1557           params:
1558             base: { get_param: vm_base_name }
1559       key_name: { get_resource: vm_key }
1560       networks:
1561         - port: { get_resource: openo_private_port }
1562       user_data_format: RAW
1563       user_data:
1564         str_replace:
1565           params:
1566             __nexus_repo__: { get_param: nexus_repo }
1567             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1568             __nexus_username__: { get_param: nexus_username }
1569             __nexus_password__: { get_param: nexus_password }
1570             __artifacts_version__: { get_param: artifacts_version }
1571             __dns_ip_addr__: { get_param: dns_ip_addr }
1572             __oam_network_cidr__: { get_param: oam_network_cidr }
1573             __aai1_ip_addr__: { get_param: aai1_ip_addr }
1574             __aai2_ip_addr__: { get_param: aai2_ip_addr }
1575             __appc_ip_addr__: { get_param: appc_ip_addr }
1576             __dcae_ip_addr__: { get_param: dcae_ip_addr }
1577             __so_ip_addr__: { get_param: so_ip_addr }
1578             __mr_ip_addr__: { get_param: mr_ip_addr }
1579             __policy_ip_addr__: { get_param: policy_ip_addr }
1580             __portal_ip_addr__: { get_param: portal_ip_addr }
1581             __robot_ip_addr__: { get_param: robot_ip_addr }
1582             __sdc_ip_addr__: { get_param: sdc_ip_addr }
1583             __sdnc_ip_addr__: { get_param: sdnc_ip_addr }
1584             __vid_ip_addr__: { get_param: vid_ip_addr }
1585             __clamp_ip_addr__: { get_param: clamp_ip_addr }
1586             __openo_ip_addr__: { get_param: openo_ip_addr }
1587             __cloud_env__: { get_param: cloud_env }
1588             __external_dns__: { get_param: external_dns }
1589             __vnfsdk_branch__: { get_param: vnfsdk_branch }
1590             __msb_docker__: { get_param: msb_docker }
1591             __mvim_docker__: { get_param: mvim_docker }
1592             __uui_docker__: { get_param: uui_docker }
1593             __esr_docker__: { get_param: esr_docker }
1594             __vnfsdk_repo__: { get_param: vnfsdk_repo }
1595             __vfc_nokia_docker__: { get_param: vfc_nokia_docker }
1596             __vfc_nokiav2_docker__: { get_param: vfc_nokiav2_docker }
1597             __cbam_ip__: { get_param: cbam_ip }
1598             __cbam_username__: { get_param: cbam_username }
1599             __cbam_password__: { get_param: cbam_password }
1600             __vfc_ztevnfmdriver_docker__: { get_param: vfc_ztevnfmdriver_docker }
1601             __vfc_multivimproxy_docker__: { get_param: vfc_multivimproxy_docker }
1602             __vfc_ztesdncdriver_docker__: { get_param: vfc_ztesdncdriver_docker }
1603             __vfc_vnfres_docker__: { get_param: vfc_vnfres_docker }
1604             __vfc_vnfmgr_docker__: { get_param: vfc_vnfmgr_docker }
1605             __vfc_vnflcm_docker__: { get_param: vfc_vnflcm_docker }
1606             __vfc_resmanagement_docker__: { get_param: vfc_resmanagement_docker }
1607             __vfc_nslcm_docker__: { get_param: vfc_nslcm_docker }
1608             __vfc_huawei_docker__: { get_param: vfc_huawei_docker }
1609             __vfc_jujudriver_docker__: { get_param: vfc_jujudriver_docker }
1610             __vfc_gvnfmdriver_docker__: { get_param: vfc_gvnfmdriver_docker }
1611             __vfc_emsdriver_docker__: { get_param: vfc_emsdriver_docker }
1612             __vfc_catalog_docker__: { get_param: vfc_catalog_docker }
1613             __vfc_wfengine_mgrservice_docker__: { get_param: vfc_wfengine_mgrservice_docker }
1614             __vfc_wfengine_activiti_docker__: { get_param: vfc_wfengine_activiti_docker }
1615           template: |
1616             #!/bin/bash
1617
1618             # Create configuration files
1619             mkdir -p /opt/config
1620             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1621             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1622             echo "__nexus_username__" > /opt/config/nexus_username.txt
1623             echo "__nexus_password__" > /opt/config/nexus_password.txt
1624             echo "__cloud_env__" > /opt/config/cloud_env.txt
1625             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1626             echo "__oam_network_cidr__" > /opt/config/oam_network_cidr.txt
1627             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1628             echo "__external_dns__" > /opt/config/external_dns.txt
1629             echo "__vnfsdk_branch__" > /opt/config/vnfsdk_branch.txt
1630             echo "__msb_docker__" > /opt/config/msb_docker.txt
1631             echo "__mvim_docker__" > /opt/config/mvim_docker.txt
1632             echo "__uui_docker__" > /opt/config/uui_docker.txt
1633             echo "__esr_docker__" > /opt/config/esr_docker.txt
1634             echo "__vnfsdk_repo__" > /opt/config/vnfsdk_repo.txt
1635             echo "__cbam_ip__" > /opt/config/cbam_ip.txt
1636             echo "__cbam_username__" > /opt/config/cbam_username.txt
1637             echo "__cbam_password__" > /opt/config/cbam_password.txt
1638
1639             echo "export NOKIA_DOCKER_VER=__vfc_nokia_docker__" >> /opt/config/vfc_docker.txt
1640             echo "export NOKIAV2_DOCKER_VER=__vfc_nokiav2_docker__" >> /opt/config/vfc_docker.txt
1641             echo "export MULTIVIMPROXY_DOCKER_VER=__vfc_multivimproxy_docker__" >> /opt/config/vfc_docker.txt
1642             echo "export ZTEVNFMDRIVER_DOCKER_VER=__vfc_ztevnfmdriver_docker__" >> /opt/config/vfc_docker.txt
1643             echo "export ZTESDNCDRIVER_DOCKER_VER=__vfc_ztesdncdriver_docker__" >> /opt/config/vfc_docker.txt
1644             echo "export VNFRES_DOCKER_VER=__vfc_vnfres_docker__" >> /opt/config/vfc_docker.txt
1645             echo "export VNFMGR_DOCKER_VER=__vfc_vnfmgr_docker__" >> /opt/config/vfc_docker.txt
1646             echo "export VNFLCM_DOCKER_VER=__vfc_vnflcm_docker__" >> /opt/config/vfc_docker.txt
1647             echo "export RESMANAGEMENT_DOCKER_VER=__vfc_resmanagement_docker__" >> /opt/config/vfc_docker.txt
1648             echo "export NSLCM_DOCKER_VER=__vfc_nslcm_docker__" >> /opt/config/vfc_docker.txt
1649             echo "export HUAWEI_DOCKER_VER=__vfc_huawei_docker__" >> /opt/config/vfc_docker.txt
1650             echo "export JUJUDRIVER_DOCKER_VER=__vfc_jujudriver_docker__" >> /opt/config/vfc_docker.txt
1651             echo "export GVNFMDRIVER_DOCKER_VER=__vfc_gvnfmdriver_docker__" >> /opt/config/vfc_docker.txt
1652             echo "export EMSDRIVER_DOCKER_VER=__vfc_emsdriver_docker__" >> /opt/config/vfc_docker.txt
1653             echo "export CATALOG_DOCKER_VER=__vfc_catalog_docker__" >> /opt/config/vfc_docker.txt
1654             echo "export MGRSERVICE_DOCKER_VER=__vfc_wfengine_mgrservice_docker__" >> /opt/config/vfc_docker.txt
1655             echo "export ACTIVITI_DOCKER_VER=__vfc_wfengine_activiti_docker__" >> /opt/config/vfc_docker.txt
1656
1657             # Create env file with the IP address of all ONAP components
1658             echo "export AAI_IP1=__aai1_ip_addr__" >> /opt/config/onap_ips.txt
1659             echo "export AAI_IP2=__aai2_ip_addr__" >> /opt/config/onap_ips.txt
1660             echo "export APPC_IP=__appc_ip_addr__" >> /opt/config/onap_ips.txt
1661             echo "export DCAE_IP=__dcae_ip_addr__" >> /opt/config/onap_ips.txt
1662             echo "export SO_IP=__so_ip_addr__" >> /opt/config/onap_ips.txt
1663             echo "export MR_IP=__mr_ip_addr__" >> /opt/config/onap_ips.txt
1664             echo "export POLICY_IP=__policy_ip_addr__" >> /opt/config/onap_ips.txt
1665             echo "export PORTAL_IP=__portal_ip_addr__" >> /opt/config/onap_ips.txt
1666             echo "export ROBOT_IP=__robot_ip_addr__" >> /opt/config/onap_ips.txt
1667             echo "export SDC_IP=__sdc_ip_addr__" >> /opt/config/onap_ips.txt
1668             echo "export SDNC_IP=__sdnc_ip_addr__" >> /opt/config/onap_ips.txt
1669             echo "export VID_IP=__vid_ip_addr__" >> /opt/config/onap_ips.txt
1670             echo "export CLAMP_IP=__clamp_ip_addr__" >> /opt/config/onap_ips.txt
1671             echo "export OPENO_IP=__openo_ip_addr__" >> /opt/config/onap_ips.txt
1672
1673             # Download and run install script
1674             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/openo_install.sh -o /opt/openo_install.sh
1675             cd /opt
1676             chmod +x openo_install.sh
1677             ./openo_install.sh
1678
1679
1680   # DCAE GEN 2 Controller instantiation
1681   dcae_c_private_port:
1682     type: OS::Neutron::Port
1683     properties:
1684       network: { get_resource: oam_onap }
1685       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: dcae_ip_addr }}]
1686       security_groups:
1687       - { get_resource: onap_sg }
1688
1689   dcae_c_floating_ip:
1690     type: OS::Neutron::FloatingIP
1691     properties:
1692       floating_network_id: { get_param: public_net_id }
1693       port_id: { get_resource: dcae_c_private_port }
1694
1695   dcae_c_vm:
1696     type: OS::Nova::Server
1697     properties:
1698       image: { get_param: ubuntu_1604_image }
1699       flavor: { get_param: flavor_small }
1700       name:
1701         str_replace:
1702           template: base-dcae-bootstrap
1703           params:
1704             base: { get_param: vm_base_name }
1705       key_name: { get_resource: vm_key }
1706       networks:
1707         - port: { get_resource: dcae_c_private_port }
1708       #security_groups:
1709       #  - { get_resource: onap_sg }
1710       user_data_format: RAW
1711       user_data:
1712         str_replace:
1713           params:
1714             __rand_str__: { get_resource: random-str }
1715             # repo related
1716             __artifacts_version__: { get_param: artifacts_version }
1717             __docker_version__: { get_param: dcae_docker }
1718             __nexus_repo__: { get_param: nexus_repo }
1719             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1720             __nexus_username__: { get_param: nexus_username }
1721             __nexus_password__: { get_param: nexus_password }
1722             # conf for the ONAP environment where the DCAE bootstrap vm/conatiner runs
1723             __mac_addr__: { get_attr: [dcae_c_private_port, mac_address] }
1724             __dcae_ip_addr__: { get_param: dcae_ip_addr }
1725             __dcae_float_ip__: { get_attr: [dcae_c_floating_ip, floating_ip_address] }
1726             __dns_ip_addr__: { get_param: dns_ip_addr }
1727             __external_dns__: { get_param: external_dns }
1728             __dns_forwarder__: { get_param: dns_forwarder }
1729             __dcae_domain__: { get_param: dcae_domain }
1730             # conf for VMs DCAE is to bringup
1731             __openstack_keystone_url__: { get_param: keystone_url }
1732             __dcae_keystone_url__: { get_param: dcae_keystone_url }
1733             __dcaeos_cloud_env__: { get_param: cloud_env }
1734             __dcaeos_keystone_url__: { get_param: dcae_keystone_url }
1735             __dcaeos_region__: { get_param: openstack_region }
1736             __dcaeos_tenant_id__: { get_param: openstack_tenant_id }
1737             __dcaeos_tenant_name__: { get_param: openstack_tenant_name }
1738             __dcaeos_security_group__:
1739               str_replace:
1740                 template: 'onap_sg_rand'
1741                 params:
1742                   rand: { get_resource: random-str }
1743             #__dcaeos_security_group__: { get_attr: [onap_sg, name] }
1744             __dcaeos_username__: { get_param: openstack_username }
1745             __dcaeos_password__: { get_param: openstack_api_key }
1746             __dcaeos_key_name__: { get_resource: vm_key }
1747             __dcaeos_public_key__: { get_param: dcae_public_key }
1748             __dcaeos_private_key__: { get_param: dcae_private_key }
1749             __dcaeos_private_network_name__: { get_attr: [oam_onap, name] }
1750             __dcaeos_public_network_name__: { get_param: public_net_name }
1751             __dcaeos_ubuntu_1604_image__: { get_param: ubuntu_1604_image }
1752             __dcaeos_centos_7_image__: { get_param: dcae_centos_7_image }
1753             __dcaeos_flavor_id__: { get_param: flavor_medium }
1754             __dcaeos_flavor_id_cdap__: { get_param: flavor_large }
1755             __dcaeos_dnsaas_config_enabled__: { get_param: dnsaas_config_enabled }
1756             __dcaeos_dnsaas_region__: { get_param: dnsaas_region }
1757             __dcaeos_dnsaas_keystone_url__: { get_param: dnsaas_keystone_url }
1758             __dnsaas_tenant_name__: { get_param: dnsaas_tenant_name }
1759             __dcaeos_dnsaas_username__: { get_param: dnsaas_username }
1760             __dcaeos_dnsaas_password__: { get_param: dnsaas_password }
1761             # fixed private IPs
1762             __mr_ip_addr__: { get_param: mr_ip_addr }
1763             __policy_ip_addr__: { get_param: policy_ip_addr }
1764             __sdc_ip_addr__: { get_param: sdc_ip_addr }
1765             __openo_ip_addr__: { get_param: openo_ip_addr }
1766             __aai1_ip_addr__: { get_param: aai1_ip_addr }
1767             __aai2_ip_addr__: { get_param: aai2_ip_addr }
1768             # floating IPs
1769             __dns_floating_ip_addr__: { get_attr: [dns_floating_ip, floating_ip_address] }
1770             __aai1_floating_ip_addr__: { get_attr: [aai1_floating_ip, floating_ip_address] }
1771             __aai2_floating_ip_addr__: { get_attr: [aai2_floating_ip, floating_ip_address] }
1772             __mrouter_floating_ip_addr__: { get_attr: [mrouter_floating_ip, floating_ip_address] }
1773             __sdc_floating_ip_addr__: { get_attr: [sdc_floating_ip, floating_ip_address] }
1774             __policy_floating_ip_addr__: { get_attr: [policy_floating_ip, floating_ip_address] }
1775             __openo_floating_ip_addr__: { get_attr: [openo_floating_ip, floating_ip_address] }
1776             __dcae_c_floating_ip_addr__: { get_attr: [dcae_c_floating_ip, floating_ip_address] }
1777
1778           template: |
1779             #!/bin/bash
1780
1781             # Create configuration files
1782             mkdir -p /opt/config
1783             echo "__rand_str__" > /opt/config/dcae_zone.txt
1784             echo "__rand_str__" > /opt/config/rand_str.txt
1785             # repo related
1786             echo "__docker_version__" > /opt/config/docker_version.txt
1787             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1788             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1789             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1790             echo "__nexus_username__" > /opt/config/nexus_username.txt
1791             echo "__nexus_password__" > /opt/config/nexus_password.txt
1792             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1793             # conf for the ONAP environment where the DCAE bootstrap vm/conatiner runs
1794             echo "__mac_addr__" > /opt/config/mac_addr.txt
1795             echo "__dcae_ip_addr__" > /opt/config/dcae_ip_addr.txt
1796             echo "__dcae_float_ip__" > /opt/config/dcae_float_ip.txt
1797             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1798             echo "__external_dns__" > /opt/config/external_dns.txt
1799             echo "__dns_forwarder__" > /opt/config/dns_forwarder.txt
1800             echo "__dcae_domain__" > /opt/config/dcae_domain.txt
1801             # conf for the OpenStack env where DCAE is deployed
1802             echo "__openstack_keystone_url__" > /opt/config/openstack_keystone_url.txt
1803             echo "__dcaeos_cloud_env__" > /opt/config/cloud_env.txt
1804             echo "__dcaeos_keystone_url__" > /opt/config/keystone_url.txt
1805             echo "__dcaeos_region__" > /opt/config/openstack_region.txt
1806             echo "__dcaeos_tenant_id__" > /opt/config/tenant_id.txt
1807             echo "__dcaeos_tenant_name__" > /opt/config/tenant_name.txt
1808             echo "__dcaeos_username__" > /opt/config/openstack_user.txt
1809             echo "__dcaeos_password__" > /opt/config/openstack_password.txt
1810             echo "__dcaeos_key_name__" > /opt/config/key_name.txt
1811             echo "__dcaeos_public_key__" > /opt/config/pub_key.txt
1812             echo "__dcaeos_private_key__" > /opt/config/priv_key
1813             echo "__dcaeos_private_network_name__" > /opt/config/openstack_private_network_name.txt
1814             echo "__dcaeos_public_network_name__" > /opt/config/public_net_name.txt
1815             echo "__dcaeos_public_network_name__" > /opt/config/public_net_id.txt
1816             echo "__dcaeos_ubuntu_1604_image__" > /opt/config/ubuntu_1604_image.txt
1817             echo "__dcaeos_centos_7_image__" > /opt/config/centos_7_image.txt
1818             echo "__dcaeos_security_group__" > /opt/config/security_group.txt
1819             echo "__dcaeos_flavor_id__" > /opt/config/flavor_id.txt
1820             echo "__dcaeos_flavor_id_cdap__" > /opt/config/flavor_id_cdap.txt
1821             echo "__dcaeos_dnsaas_config_enabled__" > /opt/config/dnsaas_config_enabled.txt
1822             echo "__dcaeos_dnsaas_region__" > /opt/config/dnsaas_region.txt
1823             echo "__dcaeos_dnsaas_keystone_url__" > /opt/config/dnsaas_keystone_url.txt
1824             echo "__dnsaas_tenant_name__" > /opt/config/dnsaas_tenant_name.txt
1825             echo "__dcaeos_dnsaas_username__" > /opt/config/dnsaas_username.txt
1826             echo "__dcaeos_dnsaas_password__" > /opt/config/dnsaas_password.txt
1827             # fixed private IP addresses of other ONAP components
1828             echo "__mr_ip_addr__" > /opt/config/mr_ip_addr.txt
1829             echo "__policy_ip_addr__" > /opt/config/policy_ip_addr.txt
1830             echo "__sdc_ip_addr__" > /opt/config/sdc_ip_addr.txt
1831             echo "__openo_ip_addr__" > /opt/config/openo_ip_addr.txt
1832             echo "__aai1_ip_addr__" > /opt/config/aai1_ip_addr.txt
1833             echo "__aai2_ip_addr__" > /opt/config/aai2_ip_addr.txt
1834             # floating IPs
1835             echo "__dns_floating_ip_addr__" > /opt/config/dns_floating_ip_addr.txt
1836             echo "__aai1_floating_ip_addr__" > /opt/config/aai1_floating_ip_addr.txt
1837             echo "__aai2_floating_ip_addr__" > /opt/config/aai2_floating_ip_addr.txt
1838             echo "__mrouter_floating_ip_addr__" > /opt/config/mrouter_floating_ip_addr.txt
1839             echo "__sdc_floating_ip_addr__" > /opt/config/sdc_floating_ip_addr.txt
1840             echo "__policy_floating_ip_addr__" > /opt/config/policy_floating_ip_addr.txt
1841             echo "__openo_floating_ip_addr__" > /opt/config/openo_floating_ip_addr.txt
1842             echo "__dcae_c_floating_ip_addr__" > /opt/config/dcae_c_floating_ip_addr.txt
1843
1844             # Download and run install script
1845             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/dcae2_install.sh -o /opt/dcae2_install.sh
1846             cd /opt
1847             chmod +x dcae2_install.sh
1848             ./dcae2_install.sh > /tmp/dcae2_install.log 2>&1
1849
1850
1851   # MUSIC instantiation
1852   music_private_port:
1853     type: OS::Neutron::Port
1854     properties:
1855       network: { get_resource: oam_onap }
1856       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: music_ip_addr }}]
1857       security_groups:
1858       - { get_resource: onap_sg }
1859
1860   music_floating_ip:
1861     type: OS::Neutron::FloatingIP
1862     properties:
1863       floating_network_id: { get_param: public_net_id }
1864       port_id: { get_resource: music_private_port }
1865
1866   music_vm:
1867     type: OS::Nova::Server
1868     properties:
1869       image: { get_param: ubuntu_1404_image }
1870       flavor: { get_param: flavor_large }
1871       name:
1872         str_replace:
1873           template: base-music
1874           params:
1875             base: { get_param: vm_base_name }
1876       key_name: { get_resource: vm_key }
1877       networks:
1878         - port: { get_resource: music_private_port }
1879       user_data_format: RAW
1880       user_data:
1881         str_replace:
1882           params:
1883             __nexus_repo__: { get_param: nexus_repo }
1884             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1885             __nexus_username__: { get_param: nexus_username }
1886             __nexus_password__: { get_param: nexus_password }
1887             __artifacts_version__: { get_param: artifacts_version }
1888             __dns_ip_addr__: { get_param: dns_ip_addr }
1889             __docker_version__: { get_param: music_docker }
1890             __music_repo__: { get_param: music_repo }
1891             __gerrit_branch__: { get_param: music_branch }
1892             __cloud_env__: { get_param: cloud_env }
1893             __external_dns__: { get_param: external_dns }
1894           template: |
1895             #!/bin/bash
1896
1897             # Create configuration files
1898             mkdir -p /opt/config
1899             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1900             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1901             echo "__nexus_username__" > /opt/config/nexus_username.txt
1902             echo "__nexus_password__" > /opt/config/nexus_password.txt
1903             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1904             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1905             echo "__docker_version__" > /opt/config/docker_version.txt
1906             echo "__music_repo__" > /opt/config/remote_repo.txt
1907             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1908             echo "__cloud_env__" > /opt/config/cloud_env.txt
1909             echo "__external_dns__" > /opt/config/external_dns.txt
1910
1911             # Download and run install script
1912             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/music_install.sh -o /opt/music_install.sh
1913             cd /opt
1914             chmod +x music_install.sh
1915             ./music_install.sh
1916
1917
1918   # OOF instantiation
1919   oof_private_port:
1920     type: OS::Neutron::Port
1921     properties:
1922       network: { get_resource: oam_onap }
1923       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: oof_ip_addr }}]
1924       security_groups:
1925       - { get_resource: onap_sg }
1926
1927   oof_floating_ip:
1928     type: OS::Neutron::FloatingIP
1929     properties:
1930       floating_network_id: { get_param: public_net_id }
1931       port_id: { get_resource: oof_private_port }
1932
1933   oof_vm:
1934     type: OS::Nova::Server
1935     properties:
1936       image: { get_param: ubuntu_1404_image }
1937       flavor: { get_param: flavor_medium }
1938       name:
1939         str_replace:
1940           template: base-oof
1941           params:
1942             base: { get_param: vm_base_name }
1943       key_name: { get_resource: vm_key }
1944       networks:
1945         - port: { get_resource: oof_private_port }
1946       user_data_format: RAW
1947       user_data:
1948         str_replace:
1949           params:
1950             __nexus_repo__: { get_param: nexus_repo }
1951             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1952             __nexus_username__: { get_param: nexus_username }
1953             __nexus_password__: { get_param: nexus_password }
1954             __artifacts_version__: { get_param: artifacts_version }
1955             __dns_ip_addr__: { get_param: dns_ip_addr }
1956             __docker_version__: { get_param: oof_docker }
1957             __oof_repo__: { get_param: oof_repo }
1958             __gerrit_branch__: { get_param: oof_branch }
1959             __cloud_env__: { get_param: cloud_env }
1960             __external_dns__: { get_param: external_dns }
1961           template: |
1962             #!/bin/bash
1963
1964             # Create configuration files
1965             mkdir -p /opt/config
1966             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1967             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1968             echo "__nexus_username__" > /opt/config/nexus_username.txt
1969             echo "__nexus_password__" > /opt/config/nexus_password.txt
1970             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1971             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1972             echo "__docker_version__" > /opt/config/docker_version.txt
1973             echo "__oof_repo__" > /opt/config/remote_repo.txt
1974             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1975             echo "__cloud_env__" > /opt/config/cloud_env.txt
1976             echo "__external_dns__" > /opt/config/external_dns.txt
1977
1978             # Download and run install script
1979             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/oof_install.sh -o /opt/oof_install.sh
1980             cd /opt
1981             chmod +x oof_install.sh
1982             ./oof_install.sh
1983
1984
1985   # AAF instantiation
1986   aaf_private_port:
1987     type: OS::Neutron::Port
1988     properties:
1989       network: { get_resource: oam_onap }
1990       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: aaf_ip_addr }}]
1991       security_groups:
1992       - { get_resource: onap_sg }
1993
1994   aaf_floating_ip:
1995     type: OS::Neutron::FloatingIP
1996     properties:
1997       floating_network_id: { get_param: public_net_id }
1998       port_id: { get_resource: aaf_private_port }
1999
2000   aaf_vm:
2001     type: OS::Nova::Server
2002     properties:
2003       image: { get_param: ubuntu_1604_image }
2004       flavor: { get_param: flavor_medium }
2005       name:
2006         str_replace:
2007           template: base-aaf
2008           params:
2009             base: { get_param: vm_base_name }
2010       key_name: { get_resource: vm_key }
2011       networks:
2012         - port: { get_resource: aaf_private_port }
2013       user_data_format: RAW
2014       user_data:
2015         str_replace:
2016           params:
2017             __nexus_repo__: { get_param: nexus_repo }
2018             __nexus_docker_repo__: { get_param: nexus_docker_repo }
2019             __nexus_username__: { get_param: nexus_username }
2020             __nexus_password__: { get_param: nexus_password }
2021             __artifacts_version__: { get_param: artifacts_version }
2022             __dns_ip_addr__: { get_param: dns_ip_addr }
2023             __docker_version__: { get_param: aaf_docker }
2024             __cloud_env__: { get_param: cloud_env }
2025             __external_dns__: { get_param: external_dns }
2026             __aaf_repo__: { get_param: aaf_repo }
2027             __gerrit_branch__: { get_param: aaf_branch }
2028           template: |
2029             #!/bin/bash
2030
2031             # Create configuration files
2032             mkdir -p /opt/config
2033             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
2034             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
2035             echo "__nexus_username__" > /opt/config/nexus_username.txt
2036             echo "__nexus_password__" > /opt/config/nexus_password.txt
2037             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
2038             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
2039             echo "__docker_version__" > /opt/config/docker_version.txt
2040             echo "__cloud_env__" > /opt/config/cloud_env.txt
2041             echo "__external_dns__" > /opt/config/external_dns.txt
2042             echo "__aaf_repo__" > /opt/config/remote_repo.txt
2043             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
2044
2045             # Download and run install script
2046             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/aaf_install.sh -o /opt/aaf_install.sh
2047             cd /opt
2048             chmod +x aaf_install.sh
2049             ./aaf_install.sh
2050
2051   # NBI instantiation
2052   nbi_private_port:
2053     type: OS::Neutron::Port
2054     properties:
2055       network: { get_resource: oam_onap }
2056       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: nbi_ip_addr }}]
2057       security_groups:
2058       - { get_resource: onap_sg }
2059
2060   nbi_floating_ip:
2061     type: OS::Neutron::FloatingIP
2062     properties:
2063       floating_network_id: { get_param: public_net_id }
2064       port_id: { get_resource: nbi_private_port }
2065
2066   nbi_vm:
2067     type: OS::Nova::Server
2068     properties:
2069       image: { get_param: ubuntu_1604_image }
2070       flavor: { get_param: flavor_small }
2071       name:
2072         str_replace:
2073           template: base-nbi
2074           params:
2075             base: { get_param: vm_base_name }
2076       key_name: { get_resource: vm_key }
2077       networks:
2078         - port: { get_resource: nbi_private_port }
2079       user_data_format: RAW
2080       user_data:
2081         str_replace:
2082           params:
2083             __nexus_repo__: { get_param: nexus_repo }
2084             __nexus_docker_repo__: { get_param: nexus_docker_repo }
2085             __nexus_username__: { get_param: nexus_username }
2086             __nexus_password__: { get_param: nexus_password }
2087             __artifacts_version__: { get_param: artifacts_version }
2088             __dns_ip_addr__: { get_param: dns_ip_addr }
2089             __docker_version__: { get_param: nbi_docker }
2090             __nbi_repo__: { get_param: nbi_repo }
2091             __gerrit_branch__: { get_param: nbi_branch }
2092             __cloud_env__: { get_param: cloud_env }
2093             __external_dns__: { get_param: external_dns }
2094           template: |
2095             #!/bin/bash
2096
2097             # Create configuration files
2098             mkdir -p /opt/config
2099             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
2100             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
2101             echo "__nexus_username__" > /opt/config/nexus_username.txt
2102             echo "__nexus_password__" > /opt/config/nexus_password.txt
2103             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
2104             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
2105             echo "__docker_version__" > /opt/config/docker_version.txt
2106             echo "__nbi_repo__" > /opt/config/remote_repo.txt
2107             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
2108             echo "__cloud_env__" > /opt/config/cloud_env.txt
2109             echo "__external_dns__" > /opt/config/external_dns.txt
2110
2111             # Download and run install script
2112             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/nbi_install.sh -o /opt/nbi_install.sh
2113             cd /opt
2114             chmod +x nbi_install.sh
2115             ./nbi_install.sh