bdbc0ee2053ad00b37661c938c659e10ad298893
[demo.git] / heat / ONAP / onap_openstack.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   sms_ip_addr:
211     type: string
212   nbi_ip_addr:
213     type: string
214
215   ###########################
216   #                         #
217   # Parameters used by DCAE #
218   #                         #
219   ###########################
220
221   dcae_deployment_profile:
222     type: string
223     description: DCAE deployment profile.  Currently supported profiles R1, R2MVP.
224
225   dnsaas_config_enabled:
226     type: string
227     description: whether the DNSaaS configuration section is enabled
228
229   dnsaas_region:
230     type: string
231     description: the region of the cloud instance providing the Designate DNS as a Service
232
233   dnsaas_keystone_url:
234     type: string
235     description: the keystone URL of the cloud instance providing the Designate DNS as a Service
236
237   dnsaas_username:
238     type: string
239     description: the username of the cloud instance providing the Designate DNS as a Service
240
241   dnsaas_password:
242     type: string
243     description: the password of the cloud instance providing the Designate DNS as a Service
244
245   dnsaas_tenant_name:
246     type: string
247     description: the name of the tenant in the cloud instance providing the Designate DNS as a Service
248
249   dcae_keystone_url:
250     type: string
251     description: the keystone URL for DCAE to use (via MultiCloud)
252
253   dcae_private_key:
254     type: string
255     description: the private key of the key-apir used between the DCAE bootstrap container and DCAE VMs
256
257   dcae_public_key:
258     type: string
259     description: the prublic key of the key-apir used between the DCAE bootstrap container and DCAE VMs
260
261   dcae_centos_7_image:
262     type: string
263     description: the id/name of the CentOS 7 VM imange
264
265   dcae_domain:
266     type: string
267     description: the top level domain to register DCAE VMs (the zone will be random-str.dcae_domain)
268
269   #####################
270   #                   #
271   # ONAP repositories #
272   #                   #
273   #####################
274
275   aai_repo:
276     type: string
277   appc_repo:
278     type: string
279   mr_repo:
280     type: string
281   so_repo:
282     type: string
283   policy_repo:
284     type: string
285   portal_repo:
286     type: string
287   robot_repo:
288     type: string
289   sdc_repo:
290     type: string
291   sdnc_repo:
292     type: string
293   vid_repo:
294     type: string
295   clamp_repo:
296     type: string
297   vnfsdk_repo:
298     type: string
299   music_repo:
300     type: string
301   nbi_repo:
302     type: string
303   aaf_repo:
304     type: string
305   sms_repo:
306     type: string
307   oof_repo:
308     type: string
309
310   ################################
311   #                              #
312   # Docker versions and branches #
313   #                              #
314   ################################
315
316   aai_docker:
317     type: string
318   aai_sparky_docker:
319     type: string
320   appc_docker:
321     type: string
322   so_docker:
323     type: string
324
325   dcae_docker:
326     type: string
327     default: latest
328   dcae_snmptrap_docker:
329     type: string
330     default: latest
331     description: Docker image version for onap/org.dcaegen2.collectors.snmptrap
332   dcae_ves_docker:
333     type: string
334     default: latest
335     description: Docker image version for onap/org.dcaegen2.collectors.ves.vescollector
336   dcae_bootstrap_docker:
337     type: string
338     default: latest
339     description: Docker image version for onap/org.dcaegen2.deployments.bootstrap
340   dcae_cm_docker:
341     type: string
342     default: latest
343     description: Docker image version for onap/org.dcaegen2.deployments.cm-container
344   dcae_k8sbootstrap_docker:
345     type: string
346     default: latest
347     description: Docker image version for onap/org.dcaegen2.deployments.k8s-bootstrap-container
348   dcae_redisc_docker:
349     type: string
350     default: latest
351     description: Docker image version for onap/org.dcaegen2.deployments.redis-cluster-container
352   dcae_tca_docker:
353     type: string
354     default: latest
355     description: Docker image version for onap/org.dcaegen2.deployments.tca-cdap-container
356   dcae_cb_docker:
357     type: string
358     default: latest
359     description: Docker image version for onap/org.dcaegen2.platform.cdapbroker
360   dcae_cbs_docker:
361     type: string
362     default: latest
363     description: Docker image version for onap/org.dcaegen2.platform.configbinding
364   dcae_dh_docker:
365     type: string
366     default: latest
367     description: Docker image version for onap/org.dcaegen2.platform.deployment-handler
368   dcae_inv_docker:
369     type: string
370     default: latest
371     description: Docker image version for onap/org.dcaegen2.platform.inventory-api
372   dcae_ph_docker:
373     type: string
374     default: latest
375     description: Docker image version for onap/org.dcaegen2.platform.deployment-handler
376   dcae_sch_docker:
377     type: string
378     default: latest
379     description: Docker image version for onap/org.dcaegen2.platform.servicechange-handler
380   dcae_heartbeat_docker:
381     type: string
382     default: latest
383     description: Docker image version for onap/org.dcaegen2.services.heartbeat
384   dcae_prh_docker:
385     type: string
386     default: latest
387     description: Docker image version for onap/org.dcaegen2.services.prh.prh-app-server
388   holmes_em_docker:
389     type: string
390     default: latest
391     description: Docker image version for onap/holmes/engine-management
392   holmes_rm_docker:
393     type: string
394     default: latest
395     description: Docker image version for onap/holmes/rule-management
396
397   policy_docker:
398     type: string
399   portal_docker:
400     type: string
401   robot_docker:
402     type: string
403   sdc_docker:
404     type: string
405   sdc_wfd_docker:
406     type: string
407   sdnc_docker:
408     type: string
409   vid_docker:
410     type: string
411   clamp_docker:
412     type: string
413   msb_docker:
414     type: string
415   mvim_docker:
416     type: string
417   mvim_openstack_docker:
418     type: string
419   uui_docker:
420     type: string
421   esr_docker:
422     type: string
423   dgbuilder_docker:
424     type: string
425   cli_docker:
426     type: string
427   music_docker:
428     type: string
429   oof_docker:
430     type: string
431   aaf_docker:
432     type: string
433   sms_docker:
434     type: string
435   nbi_docker:
436     type: string
437   dbcl_docker:
438     type: string
439
440   vfc_nokia_docker:
441     type: string
442   vfc_nokiav2_docker:
443     type: string
444   vfc_ztevnfmdriver_docker:
445     type: string
446   vfc_ztesdncdriver_docker:
447     type: string
448   vfc_vnfres_docker:
449     type: string
450   vfc_vnfmgr_docker:
451     type: string
452   vfc_vnflcm_docker:
453     type: string
454   vfc_resmanagement_docker:
455     type: string
456   vfc_nslcm_docker:
457     type: string
458   vfc_huawei_docker:
459     type: string
460   vfc_jujudriver_docker:
461     type: string
462   vfc_gvnfmdriver_docker:
463     type: string
464   vfc_emsdriver_docker:
465     type: string
466   vfc_catalog_docker:
467     type: string
468   vfc_wfengine_mgrservice_docker:
469     type: string
470   vfc_wfengine_activiti_docker:
471     type: string
472   vfc_multivimproxy_docker:
473     type: string
474
475   aai_branch:
476     type: string
477   appc_branch:
478     type: string
479   so_branch:
480     type: string
481   mr_branch:
482     type: string
483   policy_branch:
484     type: string
485   portal_branch:
486     type: string
487   robot_branch:
488     type: string
489   sdc_branch:
490     type: string
491   sdnc_branch:
492     type: string
493   vid_branch:
494     type: string
495   clamp_branch:
496     type: string
497   vnfsdk_branch:
498     type: string
499   music_branch:
500     type: string
501   nbi_branch:
502     type: string
503   aaf_branch:
504     type: string
505   sms_branch:
506     type: string
507   oof_branch:
508     type: string
509
510 #############
511 #           #
512 # RESOURCES #
513 #           #
514 #############
515
516 resources:
517   random-str:
518     type: OS::Heat::RandomString
519     properties:
520       length: 4
521
522   # Public key used to access ONAP components
523   vm_key:
524     type: OS::Nova::KeyPair
525     properties:
526       name:
527         str_replace:
528           template: base_rand
529           params:
530             base: { get_param: key_name }
531             rand: { get_resource: random-str }
532       public_key: { get_param: pub_key }
533       save_private_key: false
534
535
536   # ONAP security group
537   onap_sg:
538     type: OS::Neutron::SecurityGroup
539     properties:
540       name:
541         str_replace:
542           template: base_rand
543           params:
544             base: onap_sg
545             rand: { get_resource: random-str }
546       description: security group used by ONAP
547       rules:
548         # All egress traffic
549         - direction: egress
550           ethertype: IPv4
551         - direction: egress
552           ethertype: IPv6
553         # ingress traffic
554         # ICMP
555         - protocol: icmp
556         - protocol: udp
557           port_range_min: 1
558           port_range_max: 65535
559         - protocol: tcp
560           port_range_min: 1
561           port_range_max: 65535
562
563
564
565   # ONAP management private network
566   oam_onap:
567     type: OS::Neutron::Net
568     properties:
569       name:
570         str_replace:
571           template: oam_onap_rand
572           params:
573             rand: { get_resource: random-str }
574
575   oam_onap_subnet:
576     type: OS::Neutron::Subnet
577     properties:
578       name:
579         str_replace:
580           template: oam_onap_rand
581           params:
582             rand: { get_resource: random-str }
583       network_id: { get_resource: oam_onap }
584       cidr: { get_param: oam_network_cidr }
585       dns_nameservers: { get_param: dns_list }
586
587   router:
588     type: OS::Neutron::Router
589     properties:
590       external_gateway_info:
591         network: { get_param: public_net_id }
592
593   router_interface:
594     type: OS::Neutron::RouterInterface
595     properties:
596       router_id: { get_resource: router }
597       subnet_id: { get_resource: oam_onap_subnet }
598
599
600   # DNS Server instantiation
601   dns_private_port:
602     type: OS::Neutron::Port
603     properties:
604       network: { get_resource: oam_onap }
605       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: dns_ip_addr }}]
606       security_groups:
607       - { get_resource: onap_sg }
608
609   dns_floating_ip:
610     type: OS::Neutron::FloatingIP
611     properties:
612       floating_network_id: { get_param: public_net_id }
613       port_id: { get_resource: dns_private_port }
614
615   dns_vm:
616     type: OS::Nova::Server
617     properties:
618       image: { get_param: ubuntu_1404_image }
619       flavor: { get_param: flavor_small }
620       name:
621         str_replace:
622           template: base-dns-server
623           params:
624             base: { get_param: vm_base_name }
625       key_name: { get_resource: vm_key }
626       networks:
627         - port: { get_resource: dns_private_port }
628       user_data_format: RAW
629       user_data:
630         str_replace:
631           params:
632             __nexus_repo__: { get_param: nexus_repo }
633             __artifacts_version__: { get_param: artifacts_version }
634             __oam_network_cidr__: { get_attr: [oam_onap_subnet, cidr] }
635             __dns_ip_addr__: { get_param: dns_ip_addr }
636             __aai1_ip_addr__: { get_param: aai1_ip_addr }
637             __aai2_ip_addr__: { get_param: aai2_ip_addr }
638             __appc_ip_addr__: { get_param: appc_ip_addr }
639             __dcae_ip_addr__: { get_param: dcae_ip_addr }
640             __so_ip_addr__: { get_param: so_ip_addr }
641             __mr_ip_addr__: { get_param: mr_ip_addr }
642             __policy_ip_addr__: { get_param: policy_ip_addr }
643             __portal_ip_addr__: { get_param: portal_ip_addr }
644             __robot_ip_addr__: { get_param: robot_ip_addr }
645             __sdc_ip_addr__: { get_param: sdc_ip_addr }
646             __sdnc_ip_addr__: { get_param: sdnc_ip_addr }
647             __vid_ip_addr__: { get_param: vid_ip_addr }
648             __clamp_ip_addr__: { get_param: clamp_ip_addr }
649             __openo_ip_addr__: { get_param: openo_ip_addr }
650             __music_ip_addr__: { get_param: music_ip_addr }
651             __oof_ip_addr__: { get_param: oof_ip_addr }
652             __aaf_ip_addr__: { get_param: aaf_ip_addr }
653             __sms_ip_addr__: { get_param: sms_ip_addr }
654             __nbi_ip_addr__: { get_param: nbi_ip_addr }
655             __cloud_env__: { get_param: cloud_env }
656             __external_dns__: { get_param: external_dns }
657             __dns_forwarder__: { get_param: dns_forwarder }
658           template: |
659             #!/bin/bash
660
661             # Create configuration files
662             mkdir -p /opt/config
663             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
664             echo "__cloud_env__" > /opt/config/cloud_env.txt
665             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
666             echo "__oam_network_cidr__" > /opt/config/oam_network_cidr.txt
667             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
668             echo "__aai1_ip_addr__" > /opt/config/aai1_ip_addr.txt
669             echo "__aai2_ip_addr__" > /opt/config/aai2_ip_addr.txt
670             echo "__appc_ip_addr__" > /opt/config/appc_ip_addr.txt
671             echo "__dcae_ip_addr__" > /opt/config/dcae_ip_addr.txt
672             echo "__so_ip_addr__" > /opt/config/so_ip_addr.txt
673             echo "__mr_ip_addr__" > /opt/config/mr_ip_addr.txt
674             echo "__policy_ip_addr__" > /opt/config/policy_ip_addr.txt
675             echo "__portal_ip_addr__" > /opt/config/portal_ip_addr.txt
676             echo "__robot_ip_addr__" > /opt/config/robot_ip_addr.txt
677             echo "__sdc_ip_addr__" > /opt/config/sdc_ip_addr.txt
678             echo "__sdnc_ip_addr__" > /opt/config/sdnc_ip_addr.txt
679             echo "__vid_ip_addr__" > /opt/config/vid_ip_addr.txt
680             echo "__clamp_ip_addr__" > /opt/config/clamp_ip_addr.txt
681             echo "__openo_ip_addr__" > /opt/config/openo_ip_addr.txt
682             echo "__music_ip_addr__" > /opt/config/music_ip_addr.txt
683             echo "__oof_ip_addr__" > /opt/config/oof_ip_addr.txt
684             echo "__aaf_ip_addr__" > /opt/config/aaf_ip_addr.txt
685             echo "__sms_ip_addr__" > /opt/config/sms_ip_addr.txt
686             echo "__nbi_ip_addr__" > /opt/config/nbi_ip_addr.txt
687             echo "__external_dns__" > /opt/config/external_dns.txt
688             echo "__dns_forwarder__" > /opt/config/dns_forwarder.txt
689
690             # Download and run install script
691             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/dns_install.sh -o /opt/dns_install.sh
692             cd /opt
693             chmod +x dns_install.sh
694             ./dns_install.sh
695
696
697   # A&AI instantiation (2 VMs)
698   aai1_private_port:
699     type: OS::Neutron::Port
700     properties:
701       network: { get_resource: oam_onap }
702       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: aai1_ip_addr }}]
703       security_groups:
704       - { get_resource: onap_sg }
705
706   aai1_floating_ip:
707     type: OS::Neutron::FloatingIP
708     properties:
709       floating_network_id: { get_param: public_net_id }
710       port_id: { get_resource: aai1_private_port }
711
712   aai1_vm:
713     type: OS::Nova::Server
714     depends_on: aai2_vm
715     properties:
716       image: { get_param: ubuntu_1404_image }
717       flavor: { get_param: flavor_xlarge }
718       name:
719         str_replace:
720           template: base-aai-inst1
721           params:
722             base: { get_param: vm_base_name }
723       key_name: { get_resource: vm_key }
724       networks:
725         - port: { get_resource: aai1_private_port }
726       user_data_format: RAW
727       user_data:
728         str_replace:
729           params:
730             __nexus_repo__: { get_param: nexus_repo }
731             __nexus_docker_repo__: { get_param: nexus_docker_repo }
732             __nexus_username__: { get_param: nexus_username }
733             __nexus_password__: { get_param: nexus_password }
734             __dmaap_topic__: { get_param: dmaap_topic }
735             __artifacts_version__: { get_param: artifacts_version }
736             __dns_ip_addr__: { get_param: dns_ip_addr }
737             __docker_version__: { get_param: aai_docker }
738             __aai_sparky_docker__ : { get_param: aai_sparky_docker }
739             __gerrit_branch__: { get_param: aai_branch }
740             __cloud_env__: { get_param: cloud_env }
741             __external_dns__: { get_param: external_dns }
742             __aai_repo__: { get_param: aai_repo }
743           template: |
744             #!/bin/bash
745
746             # Create configuration files
747             mkdir -p /opt/config
748             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
749             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
750             echo "__nexus_username__" > /opt/config/nexus_username.txt
751             echo "__nexus_password__" > /opt/config/nexus_password.txt
752             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
753             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
754             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
755             echo "__docker_version__" > /opt/config/docker_version.txt
756             echo "__aai_sparky_docker__" > /opt/config/sparky_version.txt
757             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
758             echo "aai_instance_1" > /opt/config/aai_instance.txt
759             echo "__cloud_env__" > /opt/config/cloud_env.txt
760             echo "__external_dns__" > /opt/config/external_dns.txt
761             echo "__aai_repo__" > /opt/config/remote_repo.txt
762
763             # Download and run install script
764             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/aai_install.sh -o /opt/aai_install.sh
765             cd /opt
766             chmod +x aai_install.sh
767             ./aai_install.sh
768
769
770   aai2_private_port:
771     type: OS::Neutron::Port
772     properties:
773       network: { get_resource: oam_onap }
774       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: aai2_ip_addr }}]
775       security_groups:
776       - { get_resource: onap_sg }
777
778   aai2_floating_ip:
779     type: OS::Neutron::FloatingIP
780     properties:
781       floating_network_id: { get_param: public_net_id }
782       port_id: { get_resource: aai2_private_port }
783
784   aai2_vm:
785     type: OS::Nova::Server
786     properties:
787       image: { get_param: ubuntu_1404_image }
788       flavor: { get_param: flavor_xlarge }
789       name:
790         str_replace:
791           template: base-aai-inst2
792           params:
793             base: { get_param: vm_base_name }
794       key_name: { get_resource: vm_key }
795       networks:
796         - port: { get_resource: aai2_private_port }
797       user_data_format: RAW
798       user_data:
799         str_replace:
800           params:
801             __nexus_repo__: { get_param: nexus_repo }
802             __nexus_docker_repo__: { get_param: nexus_docker_repo }
803             __nexus_username__: { get_param: nexus_username }
804             __nexus_password__: { get_param: nexus_password }
805             __dmaap_topic__: { get_param: dmaap_topic }
806             __artifacts_version__: { get_param: artifacts_version }
807             __dns_ip_addr__: { get_param: dns_ip_addr }
808             __docker_version__: { get_param: aai_docker }
809             __gerrit_branch__: { get_param: aai_branch }
810             __cloud_env__: { get_param: cloud_env }
811             __external_dns__: { get_param: external_dns }
812             __aai_repo__: { get_param: aai_repo }
813           template: |
814             #!/bin/bash
815
816             # Create configuration files
817             mkdir -p /opt/config
818             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
819             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
820             echo "__nexus_username__" > /opt/config/nexus_username.txt
821             echo "__nexus_password__" > /opt/config/nexus_password.txt
822             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
823             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
824             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
825             echo "__docker_version__" > /opt/config/docker_version.txt
826             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
827             echo "aai_instance_2" > /opt/config/aai_instance.txt
828             echo "__cloud_env__" > /opt/config/cloud_env.txt
829             echo "__external_dns__" > /opt/config/external_dns.txt
830             echo "__aai_repo__" > /opt/config/remote_repo.txt
831
832             # Download and run install script
833             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/aai_install.sh -o /opt/aai_install.sh
834             cd /opt
835             chmod +x aai_install.sh
836             ./aai_install.sh
837
838
839   # SO instantiation
840   so_private_port:
841     type: OS::Neutron::Port
842     properties:
843       network: { get_resource: oam_onap }
844       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: so_ip_addr }}]
845       security_groups:
846       - { get_resource: onap_sg }
847
848   so_floating_ip:
849     type: OS::Neutron::FloatingIP
850     properties:
851       floating_network_id: { get_param: public_net_id }
852       port_id: { get_resource: so_private_port }
853
854   so_vm:
855     type: OS::Nova::Server
856     properties:
857       image: { get_param: ubuntu_1604_image }
858       flavor: { get_param: flavor_large }
859       name:
860         str_replace:
861           template: base-so
862           params:
863             base: { get_param: vm_base_name }
864       key_name: { get_resource: vm_key }
865       networks:
866         - port: { get_resource: so_private_port }
867       user_data_format: RAW
868       user_data:
869         str_replace:
870           params:
871             __nexus_repo__: { get_param: nexus_repo }
872             __nexus_docker_repo__: { get_param: nexus_docker_repo }
873             __nexus_username__: { get_param: nexus_username }
874             __nexus_password__: { get_param: nexus_password }
875             __openstack_username__: { get_param: openstack_username }
876             __openstack_tenant_id__: { get_param: openstack_tenant_id }
877             __openstack_api_key__: { get_param: openstack_api_key }
878             __openstack_region__: { get_param: openstack_region }
879             __keystone_url__: { get_param: keystone_url }
880             __dmaap_topic__: { get_param: dmaap_topic }
881             __artifacts_version__: { get_param: artifacts_version }
882             __dns_ip_addr__: { get_param: dns_ip_addr }
883             __openo_ip__: { get_param: openo_ip_addr }
884             __docker_version__: { get_param: so_docker }
885             __gerrit_branch__: { get_param: so_branch }
886             __cloud_env__: { get_param: cloud_env }
887             __external_dns__: { get_param: external_dns }
888             __so_repo__: { get_param: so_repo }
889           template: |
890             #!/bin/bash
891
892             # Create configuration files
893             mkdir -p /opt/config
894             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
895             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
896             echo "__nexus_username__" > /opt/config/nexus_username.txt
897             echo "__nexus_password__" > /opt/config/nexus_password.txt
898             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
899             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
900             echo "__openo_ip__" > /opt/config/openo_ip.txt
901             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
902             echo "__openstack_username__" > /opt/config/openstack_username.txt
903             echo "__openstack_tenant_id__" > /opt/config/tenant_id.txt
904             echo "__openstack_api_key__" > /opt/config/openstack_api_key.txt
905             echo "__openstack_region__" > /opt/config/openstack_region.txt
906             echo "__keystone_url__" > /opt/config/keystone.txt
907             echo "__docker_version__" > /opt/config/docker_version.txt
908             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
909             echo "__cloud_env__" > /opt/config/cloud_env.txt
910             echo "__external_dns__" > /opt/config/external_dns.txt
911             echo "__so_repo__" > /opt/config/remote_repo.txt
912
913             # Download and run install script
914             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/so_install.sh -o /opt/so_install.sh
915             cd /opt
916             chmod +x so_install.sh
917             ./so_install.sh
918
919
920   # Message Router instantiation
921   mrouter_private_port:
922     type: OS::Neutron::Port
923     properties:
924       network: { get_resource: oam_onap }
925       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: mr_ip_addr }}]
926       security_groups:
927       - { get_resource: onap_sg }
928
929   mrouter_floating_ip:
930     type: OS::Neutron::FloatingIP
931     properties:
932       floating_network_id: { get_param: public_net_id }
933       port_id: { get_resource: mrouter_private_port }
934
935   mrouter_vm:
936     type: OS::Nova::Server
937     properties:
938       image: { get_param: ubuntu_1404_image }
939       flavor: { get_param: flavor_large }
940       name:
941         str_replace:
942           template: base-message-router
943           params:
944             base: { get_param: vm_base_name }
945       key_name: { get_resource: vm_key }
946       networks:
947         - port: { get_resource: mrouter_private_port }
948       user_data_format: RAW
949       user_data:
950         str_replace:
951           params:
952             __nexus_repo__: { get_param: nexus_repo }
953             __nexus_docker_repo__: { get_param: nexus_docker_repo }
954             __nexus_username__: { get_param: nexus_username }
955             __nexus_password__: { get_param: nexus_password }
956             __artifacts_version__: { get_param: artifacts_version }
957             __dns_ip_addr__: { get_param: dns_ip_addr }
958             __gerrit_branch__: { get_param: mr_branch }
959             __cloud_env__: { get_param: cloud_env }
960             __external_dns__: { get_param: external_dns }
961             __mr_repo__: { get_param: mr_repo }
962             __dbcl_docker__: { get_param: dbcl_docker }
963           template: |
964             #!/bin/bash
965
966             # Create configuration files
967             mkdir -p /opt/config
968             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
969             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
970             echo "__nexus_username__" > /opt/config/nexus_username.txt
971             echo "__nexus_password__" > /opt/config/nexus_password.txt
972             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
973             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
974             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
975             echo "__cloud_env__" > /opt/config/cloud_env.txt
976             echo "__external_dns__" > /opt/config/external_dns.txt
977             echo "__mr_repo__" > /opt/config/remote_repo.txt
978             echo "__dbcl_docker__" > /opt/config/docker_version.txt
979
980             # Download and run install script
981             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/mr_install.sh -o /opt/mr_install.sh
982             cd /opt
983             chmod +x mr_install.sh
984             ./mr_install.sh
985
986
987   # Robot Framework instantiation
988   robot_private_port:
989     type: OS::Neutron::Port
990     properties:
991       network: { get_resource: oam_onap }
992       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: robot_ip_addr }}]
993       security_groups:
994       - { get_resource: onap_sg }
995
996   robot_floating_ip:
997     type: OS::Neutron::FloatingIP
998     properties:
999       floating_network_id: { get_param: public_net_id }
1000       port_id: { get_resource: robot_private_port }
1001
1002   robot_vm:
1003     type: OS::Nova::Server
1004     properties:
1005       image: { get_param: ubuntu_1604_image }
1006       flavor: { get_param: flavor_medium }
1007       name:
1008         str_replace:
1009           template: base-robot
1010           params:
1011             base: { get_param: vm_base_name }
1012       key_name: { get_resource: vm_key }
1013       networks:
1014         - port: { get_resource: robot_private_port }
1015       user_data_format: RAW
1016       user_data:
1017         str_replace:
1018           params:
1019             __nexus_repo__: { get_param: nexus_repo }
1020             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1021             __nexus_username__: { get_param: nexus_username }
1022             __nexus_password__: { get_param: nexus_password }
1023             __network_name__: { get_attr: [oam_onap, name] }
1024             __openstack_username__: { get_param: openstack_username }
1025             __openstack_api_key__: { get_param : openstack_api_key }
1026             __openstack_tenant_id__: { get_param: openstack_tenant_id }
1027             __artifacts_version__: { get_param: artifacts_version }
1028             __openstack_region__: { get_param: openstack_region }
1029             __dns_ip_addr__: { get_param: dns_ip_addr }
1030             __gerrit_branch__: { get_param: robot_branch }
1031             __cloud_env__: { get_param: cloud_env }
1032             __keystone_url__: { get_param: keystone_url }
1033             __aai1_ip_addr__: { get_param: aai1_ip_addr }
1034             __aai2_ip_addr__: { get_param: aai2_ip_addr }
1035             __appc_ip_addr__: { get_param: appc_ip_addr }
1036             __dcae_ip_addr__: { get_param: dcae_ip_addr }
1037             __dcae_collector_ip__: { get_param: dcae_ip_addr }
1038             __so_ip_addr__: { get_param: so_ip_addr }
1039             __mr_ip_addr__: { get_param: mr_ip_addr }
1040             __policy_ip_addr__: { get_param: policy_ip_addr }
1041             __portal_ip_addr__: { get_param: portal_ip_addr }
1042             __sdc_ip_addr__: { get_param: sdc_ip_addr }
1043             __sdc_fe_ip_addr__: { get_param: sdc_ip_addr }
1044             __sdc_be_ip_addr__: { get_param: sdc_ip_addr }
1045             __sdc_be_onboard_ip_addr__: { get_param: sdc_ip_addr }
1046             __sdnc_ip_addr__: { get_param: sdnc_ip_addr }
1047             __vid_ip_addr__: { get_param: vid_ip_addr }
1048             __clamp_ip_addr__: { get_param: clamp_ip_addr }
1049             __openo_ip_addr__: { get_param: openo_ip_addr }
1050             __music_ip_addr__: { get_param: music_ip_addr }
1051             __oof_ip_addr__: { get_param: oof_ip_addr }
1052             __aaf_ip_addr__: { get_param: aaf_ip_addr }
1053             __nbi_ip_addr__: { get_param: nbi_ip_addr }
1054             __external_dns__: { get_param: external_dns }
1055             __ubuntu_1404_image__: { get_param: ubuntu_1404_image }
1056             __ubuntu_1604_image__: { get_param: ubuntu_1604_image }
1057             __vm_image_name__: { get_param: ubuntu_1404_image }
1058             __vm_flavor__: { get_param: flavor_medium }
1059             __public_net_id__: { get_param: public_net_id }
1060             __script_version__: { get_param: artifacts_version }
1061             __robot_repo__: { get_param: robot_repo }
1062             __docker_version__: { get_param: robot_docker }
1063             __vnf_pub_key__: { get_param: pub_key }
1064           template: |
1065             #!/bin/bash
1066
1067             # Create configuration files
1068             mkdir -p /opt/config
1069             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1070             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1071             echo "__nexus_username__" > /opt/config/nexus_username.txt
1072             echo "__nexus_password__" > /opt/config/nexus_password.txt
1073             echo "__network_name__" > /opt/config/network.txt
1074             echo "__openstack_username__" > /opt/config/openstack_username.txt
1075             echo "__openstack_api_key__" > /opt/config/openstack_password.txt
1076             echo "__openstack_tenant_id__" > /opt/config/openstack_tenant_id.txt
1077             echo "__openstack_region__" > /opt/config/region.txt
1078             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1079             echo "__docker_version__" > /opt/config/docker_version.txt
1080             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1081             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1082             echo "__keystone_url__" > /opt/config/keystone.txt
1083             echo "__aai1_ip_addr__" > /opt/config/aai1_ip_addr.txt
1084             echo "__aai2_ip_addr__" > /opt/config/aai2_ip_addr.txt
1085             echo "__appc_ip_addr__" > /opt/config/appc_ip_addr.txt
1086             echo "__dcae_ip_addr__" > /opt/config/dcae_ip_addr.txt
1087             echo "__dcae_collector_ip__" > /opt/config/dcae_collector_ip.txt
1088             echo "__so_ip_addr__" > /opt/config/so_ip_addr.txt
1089             echo "__mr_ip_addr__" > /opt/config/mr_ip_addr.txt
1090             echo "__policy_ip_addr__" > /opt/config/policy_ip_addr.txt
1091             echo "__portal_ip_addr__" > /opt/config/portal_ip_addr.txt
1092             echo "__portal_ip_addr__" > /opt/config/cli_ip_addr.txt
1093             echo "__sdc_ip_addr__" > /opt/config/sdc_ip_addr.txt
1094             echo "__sdc_fe_ip_addr__" > /opt/config/sdc_fe_ip_addr.txt
1095             echo "__sdc_be_ip_addr__" > /opt/config/sdc_be_ip_addr.txt
1096             echo "__sdc_be_onboard_ip_addr__" > /opt/config/sdc_be_onboard_ip_addr.txt
1097             echo "__sdnc_ip_addr__" > /opt/config/sdnc_ip_addr.txt
1098             echo "__vid_ip_addr__" > /opt/config/vid_ip_addr.txt
1099             echo "__clamp_ip_addr__" > /opt/config/clamp_ip_addr.txt
1100             echo "__openo_ip_addr__" > /opt/config/openo_ip_addr.txt
1101             echo "__openo_ip_addr__" > /opt/config/vnfsdk_ip_addr.txt
1102             echo "__music_ip_addr__" > /opt/config/music_ip_addr.txt
1103             echo "__oof_ip_addr__" > /opt/config/oof_ip_addr.txt
1104             echo "__aaf_ip_addr__" > /opt/config/aaf_ip_addr.txt
1105             echo "__nbi_ip_addr__" > /opt/config/nbi_ip_addr.txt
1106             echo "__cloud_env__" > /opt/config/cloud_env.txt
1107             echo "__external_dns__" > /opt/config/external_dns.txt
1108             echo "__vm_flavor__" > /opt/config/vm_flavor.txt
1109             echo "__ubuntu_1404_image__" > /opt/config/ubuntu_1404_image.txt
1110             echo "__ubuntu_1604_image__" > /opt/config/ubuntu_1604_image.txt
1111             echo "__vm_image_name__" > /opt/config/vm_image_name.txt
1112             echo "__script_version__" > /opt/config/script_version.txt
1113             echo "__public_net_id__" > /opt/config/public_net_id.txt
1114             echo "__vnf_pub_key__" > /opt/config/vnf_pub_key.txt
1115             echo "__robot_repo__" > /opt/config/remote_repo.txt
1116             echo "localhost" > /opt/config/log_elasticsearch_ip_addr.txt # these tests will be skipped by robot
1117             echo "localhost" > /opt/config/log_logstash_ip_addr.txt # these tests will be skipped by robot
1118             echo "localhost" > /opt/config/log_kibana_ip_addr.txt # these tests will be skipped by robot
1119
1120             # Download and run install script
1121             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/robot_install.sh -o /opt/robot_install.sh
1122             cd /opt
1123             chmod +x robot_install.sh
1124             ./robot_install.sh
1125
1126
1127   # VID instantiation
1128   vid_private_port:
1129     type: OS::Neutron::Port
1130     properties:
1131       network: { get_resource: oam_onap }
1132       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: vid_ip_addr }}]
1133       security_groups:
1134       - { get_resource: onap_sg }
1135
1136   vid_floating_ip:
1137     type: OS::Neutron::FloatingIP
1138     properties:
1139       floating_network_id: { get_param: public_net_id }
1140       port_id: { get_resource: vid_private_port }
1141
1142   vid_vm:
1143     type: OS::Nova::Server
1144     properties:
1145       image: { get_param: ubuntu_1404_image }
1146       flavor: { get_param: flavor_medium }
1147       name:
1148         str_replace:
1149           template: base-vid
1150           params:
1151             base: { get_param: vm_base_name }
1152       key_name: { get_resource: vm_key }
1153       networks:
1154         - port: { get_resource: vid_private_port }
1155       user_data_format: RAW
1156       user_data:
1157         str_replace:
1158           params:
1159             __nexus_repo__: { get_param: nexus_repo }
1160             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1161             __nexus_username__: { get_param: nexus_username }
1162             __nexus_password__: { get_param: nexus_password }
1163             __artifacts_version__: { get_param: artifacts_version }
1164             __dns_ip_addr__: { get_param: dns_ip_addr }
1165             __docker_version__: { get_param: vid_docker }
1166             __gerrit_branch__: { get_param: vid_branch }
1167             __cloud_env__: { get_param: cloud_env }
1168             __external_dns__: { get_param: external_dns }
1169             __vid_repo__: { get_param: vid_repo }
1170           template: |
1171             #!/bin/bash
1172
1173             # Create configuration files
1174             mkdir -p /opt/config
1175             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1176             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1177             echo "__nexus_username__" > /opt/config/nexus_username.txt
1178             echo "__nexus_password__" > /opt/config/nexus_password.txt
1179             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1180             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1181             echo "__docker_version__" > /opt/config/docker_version.txt
1182             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1183             echo "__cloud_env__" > /opt/config/cloud_env.txt
1184             echo "__external_dns__" > /opt/config/external_dns.txt
1185             echo "__vid_repo__" > /opt/config/remote_repo.txt
1186
1187             # Download and run install script
1188             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/vid_install.sh -o /opt/vid_install.sh
1189             cd /opt
1190             chmod +x vid_install.sh
1191             ./vid_install.sh
1192
1193
1194   # SDN-C instantiation
1195   sdnc_private_port:
1196     type: OS::Neutron::Port
1197     properties:
1198       network: { get_resource: oam_onap }
1199       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: sdnc_ip_addr }}]
1200       security_groups:
1201       - { get_resource: onap_sg }
1202
1203   sdnc_floating_ip:
1204     type: OS::Neutron::FloatingIP
1205     properties:
1206       floating_network_id: { get_param: public_net_id }
1207       port_id: { get_resource: sdnc_private_port }
1208
1209   sdnc_vm:
1210     type: OS::Nova::Server
1211     properties:
1212       image: { get_param: ubuntu_1404_image }
1213       flavor: { get_param: flavor_large }
1214       name:
1215         str_replace:
1216           template: base-sdnc
1217           params:
1218             base: { get_param: vm_base_name }
1219       key_name: { get_resource: vm_key }
1220       networks:
1221         - port: { get_resource: sdnc_private_port }
1222       user_data_format: RAW
1223       user_data:
1224         str_replace:
1225           params:
1226             __nexus_repo__: { get_param: nexus_repo }
1227             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1228             __nexus_username__: { get_param: nexus_username }
1229             __nexus_password__: { get_param: nexus_password }
1230             __artifacts_version__: { get_param: artifacts_version }
1231             __dns_ip_addr__: { get_param: dns_ip_addr }
1232             __docker_version__: { get_param: sdnc_docker }
1233             __gerrit_branch__: { get_param: sdnc_branch }
1234             __dgbuilder_docker__: { get_param: dgbuilder_docker }
1235             __cloud_env__: { get_param: cloud_env }
1236             __external_dns__: { get_param: external_dns }
1237             __sdnc_repo__: { get_param: sdnc_repo }
1238           template: |
1239             #!/bin/bash
1240
1241             # Create configuration files
1242             mkdir -p /opt/config
1243             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1244             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1245             echo "__nexus_username__" > /opt/config/nexus_username.txt
1246             echo "__nexus_password__" > /opt/config/nexus_password.txt
1247             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1248             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1249             echo "__docker_version__" > /opt/config/docker_version.txt
1250             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1251             echo "__dgbuilder_docker__" > /opt/config/dgbuilder_version.txt
1252             echo "__cloud_env__" > /opt/config/cloud_env.txt
1253             echo "__external_dns__" > /opt/config/external_dns.txt
1254             echo "__sdnc_repo__" > /opt/config/remote_repo.txt
1255
1256             # Download and run install script
1257             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/sdnc_install.sh -o /opt/sdnc_install.sh
1258             cd /opt
1259             chmod +x sdnc_install.sh
1260             ./sdnc_install.sh
1261
1262
1263   # SDC instantiation
1264   sdc_private_port:
1265     type: OS::Neutron::Port
1266     properties:
1267       network: { get_resource: oam_onap }
1268       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: sdc_ip_addr }}]
1269       security_groups:
1270       - { get_resource: onap_sg }
1271
1272   sdc_floating_ip:
1273     type: OS::Neutron::FloatingIP
1274     properties:
1275       floating_network_id: { get_param: public_net_id }
1276       port_id: { get_resource: sdc_private_port }
1277
1278   sdc_volume_data:
1279     type: OS::Cinder::Volume
1280     properties:
1281       name: vol1-sdc-data
1282       size: 100
1283
1284   sdc_vm:
1285     type: OS::Nova::Server
1286     properties:
1287       image: { get_param: ubuntu_1604_image }
1288       flavor: { get_param: flavor_xlarge }
1289       name:
1290         str_replace:
1291           template: base-sdc
1292           params:
1293             base: { get_param: vm_base_name }
1294       key_name: { get_resource: vm_key }
1295       networks:
1296         - port: { get_resource: sdc_private_port }
1297       block_device_mapping:
1298         - device_name: /dev/vdb
1299           volume_id: {get_resource: sdc_volume_data}
1300       user_data_format: RAW
1301       user_data:
1302         str_replace:
1303           params:
1304             __nexus_repo__: { get_param: nexus_repo }
1305             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1306             __nexus_username__: { get_param: nexus_username }
1307             __nexus_password__: { get_param: nexus_password }
1308             __env_name__: { get_param: dmaap_topic }
1309             __artifacts_version__: { get_param: artifacts_version }
1310             __dns_ip_addr__: { get_param: dns_ip_addr }
1311             __mr_ip_addr__: { get_param: mr_ip_addr }
1312             __private_ip__: { get_param: sdc_ip_addr }
1313             __docker_version__: { get_param: sdc_docker }
1314             __sdc_wfd_docker__: { get_param: sdc_wfd_docker }
1315             __gerrit_branch__: { get_param: sdc_branch }
1316             __cloud_env__: { get_param: cloud_env }
1317             __external_dns__: { get_param: external_dns }
1318             __sdc_repo__: { get_param: sdc_repo }
1319           template: |
1320             #!/bin/bash
1321
1322             # Create configuration files
1323             mkdir -p /opt/config
1324             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1325             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1326             echo "__nexus_username__" > /opt/config/nexus_username.txt
1327             echo "__nexus_password__" > /opt/config/nexus_password.txt
1328             echo "__env_name__" > /opt/config/env_name.txt
1329             echo "__mr_ip_addr__" > /opt/config/mr_ip_addr.txt
1330             echo "__private_ip__" > /opt/config/private_ip.txt
1331             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1332             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1333             echo "__docker_version__" > /opt/config/docker_version.txt
1334             echo "__sdc_wfd_docker__" > /opt/config/sdc_wfd_docker.txt
1335             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1336             echo "__cloud_env__" > /opt/config/cloud_env.txt
1337             echo "__external_dns__" > /opt/config/external_dns.txt
1338             echo "__sdc_repo__" > /opt/config/remote_repo.txt
1339
1340             # Download and run install script
1341             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/sdc_install.sh -o /opt/sdc_install.sh
1342             cd /opt
1343             chmod +x sdc_install.sh
1344             ./sdc_install.sh
1345
1346
1347   # PORTAL instantiation
1348   portal_private_port:
1349     type: OS::Neutron::Port
1350     properties:
1351       network: { get_resource: oam_onap }
1352       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: portal_ip_addr }}]
1353       security_groups:
1354       - { get_resource: onap_sg }
1355
1356   portal_floating_ip:
1357     type: OS::Neutron::FloatingIP
1358     properties:
1359       floating_network_id: { get_param: public_net_id }
1360       port_id: { get_resource: portal_private_port }
1361
1362   portal_vm:
1363     type: OS::Nova::Server
1364     properties:
1365       image: { get_param: ubuntu_1404_image }
1366       flavor: { get_param: flavor_large }
1367       name:
1368         str_replace:
1369           template: base-portal
1370           params:
1371             base: { get_param: vm_base_name }
1372       key_name: { get_resource: vm_key }
1373       networks:
1374         - port: { get_resource: portal_private_port }
1375       user_data_format: RAW
1376       user_data:
1377         str_replace:
1378           params:
1379             __nexus_repo__: { get_param: nexus_repo }
1380             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1381             __nexus_username__: { get_param: nexus_username }
1382             __nexus_password__: { get_param: nexus_password }
1383             __artifacts_version__: { get_param: artifacts_version }
1384             __dns_ip_addr__: { get_param: dns_ip_addr }
1385             __public_ip__: { get_attr: [portal_floating_ip, floating_ip_address] }
1386             __docker_version__: { get_param: portal_docker }
1387             __gerrit_branch__: { get_param: portal_branch }
1388             __cli_docker__: { get_param: cli_docker }
1389             __cloud_env__: { get_param: cloud_env }
1390             __external_dns__: { get_param: external_dns }
1391             __portal_repo__: { get_param: portal_repo }
1392           template: |
1393             #!/bin/bash
1394
1395             # Create configuration files
1396             mkdir -p /opt/config
1397             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1398             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1399             echo "__nexus_username__" > /opt/config/nexus_username.txt
1400             echo "__nexus_password__" > /opt/config/nexus_password.txt
1401             echo "__public_ip__" > /opt/config/public_ip.txt
1402             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1403             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1404             echo "__docker_version__" > /opt/config/docker_version.txt
1405             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1406             echo "__cli_docker__" > /opt/config/cli_docker_version.txt
1407             echo "__cloud_env__" > /opt/config/cloud_env.txt
1408             echo "__external_dns__" > /opt/config/external_dns.txt
1409             echo "__portal_repo__" > /opt/config/remote_repo.txt
1410
1411             # Download and run install script
1412             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/portal_install.sh -o /opt/portal_install.sh
1413             cd /opt
1414             chmod +x portal_install.sh
1415             ./portal_install.sh
1416
1417
1418   # Policy Engine instantiation
1419   policy_private_port:
1420     type: OS::Neutron::Port
1421     properties:
1422       network: { get_resource: oam_onap }
1423       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: policy_ip_addr }}]
1424       security_groups:
1425       - { get_resource: onap_sg }
1426
1427   policy_floating_ip:
1428     type: OS::Neutron::FloatingIP
1429     properties:
1430       floating_network_id: { get_param: public_net_id }
1431       port_id: { get_resource: policy_private_port }
1432
1433   policy_vm:
1434     type: OS::Nova::Server
1435     properties:
1436       image: { get_param: ubuntu_1404_image }
1437       flavor: { get_param: flavor_xlarge }
1438       name:
1439         str_replace:
1440           template: base-policy
1441           params:
1442             base: { get_param: vm_base_name }
1443       key_name: { get_resource: vm_key }
1444       networks:
1445         - port: { get_resource: policy_private_port }
1446       user_data_format: RAW
1447       user_data:
1448         str_replace:
1449           params:
1450             __nexus_repo__: { get_param: nexus_repo }
1451             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1452             __nexus_username__: { get_param: nexus_username }
1453             __nexus_password__: { get_param: nexus_password }
1454             __artifacts_version__: { get_param: artifacts_version }
1455             __dns_ip_addr__: { get_param: dns_ip_addr }
1456             __public_ip__: { get_attr: [policy_floating_ip, floating_ip_address] }
1457             __docker_version__: { get_param: policy_docker }
1458             __gerrit_branch__: { get_param: policy_branch }
1459             __cloud_env__: { get_param: cloud_env }
1460             __external_dns__: { get_param: external_dns }
1461             __policy_repo__: { get_param: policy_repo }
1462           template: |
1463             #!/bin/bash
1464
1465             # Create configuration files
1466             mkdir -p /opt/config
1467             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1468             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1469             echo "__nexus_username__" > /opt/config/nexus_username.txt
1470             echo "__nexus_password__" > /opt/config/nexus_password.txt
1471             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1472             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1473             echo "__public_ip__" > /opt/config/public_ip.txt
1474             echo "__docker_version__" > /opt/config/docker_version.txt
1475             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1476             echo "__cloud_env__" > /opt/config/cloud_env.txt
1477             echo "__external_dns__" > /opt/config/external_dns.txt
1478             echo "__policy_repo__" > /opt/config/remote_repo.txt
1479
1480             # Download and run install script
1481             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/policy_install.sh -o /opt/policy_install.sh
1482             cd /opt
1483             chmod +x policy_install.sh
1484             ./policy_install.sh
1485
1486
1487   # APP-C instantiation
1488   appc_private_port:
1489     type: OS::Neutron::Port
1490     properties:
1491       network: { get_resource: oam_onap }
1492       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: appc_ip_addr }}]
1493       security_groups:
1494       - { get_resource: onap_sg }
1495
1496   appc_floating_ip:
1497     type: OS::Neutron::FloatingIP
1498     properties:
1499       floating_network_id: { get_param: public_net_id }
1500       port_id: { get_resource: appc_private_port }
1501
1502   appc_vm:
1503     type: OS::Nova::Server
1504     properties:
1505       image: { get_param: ubuntu_1404_image }
1506       flavor: { get_param: flavor_large }
1507       name:
1508         str_replace:
1509           template: base-appc
1510           params:
1511             base: { get_param: vm_base_name }
1512       key_name: { get_resource: vm_key }
1513       networks:
1514         - port: { get_resource: appc_private_port }
1515       user_data_format: RAW
1516       user_data:
1517         str_replace:
1518           params:
1519             __nexus_repo__: { get_param: nexus_repo }
1520             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1521             __nexus_username__: { get_param: nexus_username }
1522             __nexus_password__: { get_param: nexus_password }
1523             __dmaap_topic__: { get_param: dmaap_topic }
1524             __artifacts_version__: { get_param: artifacts_version }
1525             __dns_ip_addr__: { get_param: dns_ip_addr }
1526             __docker_version__: { get_param: appc_docker }
1527             __gerrit_branch__: { get_param: appc_branch }
1528             __dgbuilder_docker__: { get_param: dgbuilder_docker }
1529             __cloud_env__: { get_param: cloud_env }
1530             __external_dns__: { get_param: external_dns }
1531             __appc_repo__: { get_param: appc_repo }
1532           template: |
1533             #!/bin/bash
1534
1535             # Create configuration files
1536             mkdir -p /opt/config
1537             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1538             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1539             echo "__nexus_username__" > /opt/config/nexus_username.txt
1540             echo "__nexus_password__" > /opt/config/nexus_password.txt
1541             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1542             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1543             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
1544             echo "__docker_version__" > /opt/config/docker_version.txt
1545             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1546             echo "__dgbuilder_docker__" > /opt/config/dgbuilder_version.txt
1547             echo "__cloud_env__" > /opt/config/cloud_env.txt
1548             echo "__external_dns__" > /opt/config/external_dns.txt
1549             echo "__appc_repo__" > /opt/config/remote_repo.txt
1550
1551             # Download and run install script
1552             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/appc_install.sh -o /opt/appc_install.sh
1553             cd /opt
1554             chmod +x appc_install.sh
1555             ./appc_install.sh
1556
1557
1558   # CLAMP instantiation
1559   clamp_private_port:
1560     type: OS::Neutron::Port
1561     properties:
1562       network: { get_resource: oam_onap }
1563       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: clamp_ip_addr }}]
1564       security_groups:
1565       - { get_resource: onap_sg }
1566
1567   clamp_floating_ip:
1568     type: OS::Neutron::FloatingIP
1569     properties:
1570       floating_network_id: { get_param: public_net_id }
1571       port_id: { get_resource: clamp_private_port }
1572
1573   clamp_vm:
1574     type: OS::Nova::Server
1575     properties:
1576       image: { get_param: ubuntu_1604_image }
1577       flavor: { get_param: flavor_medium }
1578       name:
1579         str_replace:
1580           template: base-clamp
1581           params:
1582             base: { get_param: vm_base_name }
1583       key_name: { get_resource: vm_key }
1584       networks:
1585         - port: { get_resource: clamp_private_port }
1586       user_data_format: RAW
1587       user_data:
1588         str_replace:
1589           params:
1590             __nexus_repo__: { get_param: nexus_repo }
1591             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1592             __nexus_username__: { get_param: nexus_username }
1593             __nexus_password__: { get_param: nexus_password }
1594             __openstack_username__: { get_param: openstack_username }
1595             __openstack_tenant_id__: { get_param: openstack_tenant_id }
1596             __openstack_api_key__: { get_param: openstack_api_key }
1597             __openstack_region__: { get_param: openstack_region }
1598             __keystone_url__: { get_param: keystone_url }
1599             __dmaap_topic__: { get_param: dmaap_topic }
1600             __artifacts_version__: { get_param: artifacts_version }
1601             __dns_ip_addr__: { get_param: dns_ip_addr }
1602             __docker_version__: { get_param: clamp_docker }
1603             __gerrit_branch__: { get_param: clamp_branch }
1604             __cloud_env__: { get_param: cloud_env }
1605             __external_dns__: { get_param: external_dns }
1606             __clamp_repo__: { get_param: clamp_repo }
1607           template: |
1608             #!/bin/bash
1609
1610             # Create configuration files
1611             mkdir -p /opt/config
1612             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1613             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1614             echo "__nexus_username__" > /opt/config/nexus_username.txt
1615             echo "__nexus_password__" > /opt/config/nexus_password.txt
1616             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1617             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1618             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
1619             echo "__openstack_username__" > /opt/config/openstack_username.txt
1620             echo "__openstack_tenant_id__" > /opt/config/tenant_id.txt
1621             echo "__openstack_api_key__" > /opt/config/openstack_api_key.txt
1622             echo "__openstack_region__" > /opt/config/openstack_region.txt
1623             echo "__keystone_url__" > /opt/config/keystone.txt
1624             echo "__docker_version__" > /opt/config/docker_version.txt
1625             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1626             echo "__cloud_env__" > /opt/config/cloud_env.txt
1627             echo "__external_dns__" > /opt/config/external_dns.txt
1628             echo "__clamp_repo__" > /opt/config/remote_repo.txt
1629
1630             # Download and run install script
1631             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/clamp_install.sh -o /opt/clamp_install.sh
1632             cd /opt
1633             chmod +x clamp_install.sh
1634             ./clamp_install.sh
1635
1636
1637   # OPEN-O VM instantiation
1638   openo_private_port:
1639     type: OS::Neutron::Port
1640     properties:
1641       network: { get_resource: oam_onap }
1642       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: openo_ip_addr }}]
1643       security_groups:
1644       - { get_resource: onap_sg }
1645
1646   openo_floating_ip:
1647     type: OS::Neutron::FloatingIP
1648     properties:
1649       floating_network_id: { get_param: public_net_id }
1650       port_id: { get_resource: openo_private_port }
1651
1652   openo_vm:
1653     type: OS::Nova::Server
1654     properties:
1655       image: { get_param: ubuntu_1604_image }
1656       flavor: { get_param: flavor_xlarge }
1657       name:
1658         str_replace:
1659           template: base-multi-service
1660           params:
1661             base: { get_param: vm_base_name }
1662       key_name: { get_resource: vm_key }
1663       networks:
1664         - port: { get_resource: openo_private_port }
1665       user_data_format: RAW
1666       user_data:
1667         str_replace:
1668           params:
1669             __nexus_repo__: { get_param: nexus_repo }
1670             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1671             __nexus_username__: { get_param: nexus_username }
1672             __nexus_password__: { get_param: nexus_password }
1673             __artifacts_version__: { get_param: artifacts_version }
1674             __dns_ip_addr__: { get_param: dns_ip_addr }
1675             __oam_network_cidr__: { get_param: oam_network_cidr }
1676             __aai1_ip_addr__: { get_param: aai1_ip_addr }
1677             __aai2_ip_addr__: { get_param: aai2_ip_addr }
1678             __appc_ip_addr__: { get_param: appc_ip_addr }
1679             __dcae_ip_addr__: { get_param: dcae_ip_addr }
1680             __so_ip_addr__: { get_param: so_ip_addr }
1681             __mr_ip_addr__: { get_param: mr_ip_addr }
1682             __policy_ip_addr__: { get_param: policy_ip_addr }
1683             __portal_ip_addr__: { get_param: portal_ip_addr }
1684             __robot_ip_addr__: { get_param: robot_ip_addr }
1685             __sdc_ip_addr__: { get_param: sdc_ip_addr }
1686             __sdnc_ip_addr__: { get_param: sdnc_ip_addr }
1687             __vid_ip_addr__: { get_param: vid_ip_addr }
1688             __clamp_ip_addr__: { get_param: clamp_ip_addr }
1689             __openo_ip_addr__: { get_param: openo_ip_addr }
1690             __cloud_env__: { get_param: cloud_env }
1691             __external_dns__: { get_param: external_dns }
1692             __vnfsdk_branch__: { get_param: vnfsdk_branch }
1693             __msb_docker__: { get_param: msb_docker }
1694             __mvim_docker__: { get_param: mvim_docker }
1695             __mvim_openstack_docker__: { get_param: mvim_openstack_docker }
1696             __uui_docker__: { get_param: uui_docker }
1697             __esr_docker__: { get_param: esr_docker }
1698             __vnfsdk_repo__: { get_param: vnfsdk_repo }
1699             __vfc_nokia_docker__: { get_param: vfc_nokia_docker }
1700             __vfc_nokiav2_docker__: { get_param: vfc_nokiav2_docker }
1701             __vfc_ztevnfmdriver_docker__: { get_param: vfc_ztevnfmdriver_docker }
1702             __vfc_multivimproxy_docker__: { get_param: vfc_multivimproxy_docker }
1703             __vfc_ztesdncdriver_docker__: { get_param: vfc_ztesdncdriver_docker }
1704             __vfc_vnfres_docker__: { get_param: vfc_vnfres_docker }
1705             __vfc_vnfmgr_docker__: { get_param: vfc_vnfmgr_docker }
1706             __vfc_vnflcm_docker__: { get_param: vfc_vnflcm_docker }
1707             __vfc_resmanagement_docker__: { get_param: vfc_resmanagement_docker }
1708             __vfc_nslcm_docker__: { get_param: vfc_nslcm_docker }
1709             __vfc_huawei_docker__: { get_param: vfc_huawei_docker }
1710             __vfc_jujudriver_docker__: { get_param: vfc_jujudriver_docker }
1711             __vfc_gvnfmdriver_docker__: { get_param: vfc_gvnfmdriver_docker }
1712             __vfc_emsdriver_docker__: { get_param: vfc_emsdriver_docker }
1713             __vfc_catalog_docker__: { get_param: vfc_catalog_docker }
1714             __vfc_wfengine_mgrservice_docker__: { get_param: vfc_wfengine_mgrservice_docker }
1715             __vfc_wfengine_activiti_docker__: { get_param: vfc_wfengine_activiti_docker }
1716           template: |
1717             #!/bin/bash
1718
1719             # Create configuration files
1720             mkdir -p /opt/config
1721             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1722             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1723             echo "__nexus_username__" > /opt/config/nexus_username.txt
1724             echo "__nexus_password__" > /opt/config/nexus_password.txt
1725             echo "__cloud_env__" > /opt/config/cloud_env.txt
1726             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1727             echo "__oam_network_cidr__" > /opt/config/oam_network_cidr.txt
1728             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1729             echo "__external_dns__" > /opt/config/external_dns.txt
1730             echo "__vnfsdk_branch__" > /opt/config/vnfsdk_branch.txt
1731             echo "__msb_docker__" > /opt/config/msb_docker.txt
1732             echo "__mvim_docker__" > /opt/config/mvim_docker.txt
1733             echo "__mvim_openstack_docker__" > /opt/config/mvim_openstack_docker.txt
1734             echo "__uui_docker__" > /opt/config/uui_docker.txt
1735             echo "__esr_docker__" > /opt/config/esr_docker.txt
1736             echo "__vnfsdk_repo__" > /opt/config/vnfsdk_repo.txt
1737
1738             echo "export NOKIA_DOCKER_VER=__vfc_nokia_docker__" >> /opt/config/vfc_docker.txt
1739             echo "export NOKIAV2_DOCKER_VER=__vfc_nokiav2_docker__" >> /opt/config/vfc_docker.txt
1740             echo "export MULTIVIMPROXY_DOCKER_VER=__vfc_multivimproxy_docker__" >> /opt/config/vfc_docker.txt
1741             echo "export ZTEVNFMDRIVER_DOCKER_VER=__vfc_ztevnfmdriver_docker__" >> /opt/config/vfc_docker.txt
1742             echo "export ZTESDNCDRIVER_DOCKER_VER=__vfc_ztesdncdriver_docker__" >> /opt/config/vfc_docker.txt
1743             echo "export VNFRES_DOCKER_VER=__vfc_vnfres_docker__" >> /opt/config/vfc_docker.txt
1744             echo "export VNFMGR_DOCKER_VER=__vfc_vnfmgr_docker__" >> /opt/config/vfc_docker.txt
1745             echo "export VNFLCM_DOCKER_VER=__vfc_vnflcm_docker__" >> /opt/config/vfc_docker.txt
1746             echo "export RESMANAGEMENT_DOCKER_VER=__vfc_resmanagement_docker__" >> /opt/config/vfc_docker.txt
1747             echo "export NSLCM_DOCKER_VER=__vfc_nslcm_docker__" >> /opt/config/vfc_docker.txt
1748             echo "export HUAWEI_DOCKER_VER=__vfc_huawei_docker__" >> /opt/config/vfc_docker.txt
1749             echo "export JUJUDRIVER_DOCKER_VER=__vfc_jujudriver_docker__" >> /opt/config/vfc_docker.txt
1750             echo "export GVNFMDRIVER_DOCKER_VER=__vfc_gvnfmdriver_docker__" >> /opt/config/vfc_docker.txt
1751             echo "export EMSDRIVER_DOCKER_VER=__vfc_emsdriver_docker__" >> /opt/config/vfc_docker.txt
1752             echo "export CATALOG_DOCKER_VER=__vfc_catalog_docker__" >> /opt/config/vfc_docker.txt
1753             echo "export MGRSERVICE_DOCKER_VER=__vfc_wfengine_mgrservice_docker__" >> /opt/config/vfc_docker.txt
1754             echo "export ACTIVITI_DOCKER_VER=__vfc_wfengine_activiti_docker__" >> /opt/config/vfc_docker.txt
1755
1756             # Create env file with the IP address of all ONAP components
1757             echo "export AAI_IP1=__aai1_ip_addr__" >> /opt/config/onap_ips.txt
1758             echo "export AAI_IP2=__aai2_ip_addr__" >> /opt/config/onap_ips.txt
1759             echo "export APPC_IP=__appc_ip_addr__" >> /opt/config/onap_ips.txt
1760             echo "export DCAE_IP=__dcae_ip_addr__" >> /opt/config/onap_ips.txt
1761             echo "export SO_IP=__so_ip_addr__" >> /opt/config/onap_ips.txt
1762             echo "export MR_IP=__mr_ip_addr__" >> /opt/config/onap_ips.txt
1763             echo "export POLICY_IP=__policy_ip_addr__" >> /opt/config/onap_ips.txt
1764             echo "export PORTAL_IP=__portal_ip_addr__" >> /opt/config/onap_ips.txt
1765             echo "export ROBOT_IP=__robot_ip_addr__" >> /opt/config/onap_ips.txt
1766             echo "export SDC_IP=__sdc_ip_addr__" >> /opt/config/onap_ips.txt
1767             echo "export SDNC_IP=__sdnc_ip_addr__" >> /opt/config/onap_ips.txt
1768             echo "export VID_IP=__vid_ip_addr__" >> /opt/config/onap_ips.txt
1769             echo "export CLAMP_IP=__clamp_ip_addr__" >> /opt/config/onap_ips.txt
1770             echo "export OPENO_IP=__openo_ip_addr__" >> /opt/config/onap_ips.txt
1771
1772             # Download and run install script
1773             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/openo_install.sh -o /opt/openo_install.sh
1774             cd /opt
1775             chmod +x openo_install.sh
1776             ./openo_install.sh
1777
1778
1779   # DCAE GEN 2 Controller instantiation
1780   dcae_c_private_port:
1781     type: OS::Neutron::Port
1782     properties:
1783       network: { get_resource: oam_onap }
1784       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: dcae_ip_addr }}]
1785       security_groups:
1786       - { get_resource: onap_sg }
1787
1788   dcae_c_floating_ip:
1789     type: OS::Neutron::FloatingIP
1790     properties:
1791       floating_network_id: { get_param: public_net_id }
1792       port_id: { get_resource: dcae_c_private_port }
1793
1794   dcae_c_vm:
1795     type: OS::Nova::Server
1796     properties:
1797       image: { get_param: ubuntu_1604_image }
1798       flavor: { get_param: flavor_xlarge }
1799       name:
1800         str_replace:
1801           template: base-dcae
1802           params:
1803             base: { get_param: vm_base_name }
1804       key_name: { get_resource: vm_key }
1805       networks:
1806         - port: { get_resource: dcae_c_private_port }
1807       #security_groups:
1808       #  - { get_resource: onap_sg }
1809       user_data_format: RAW
1810       user_data:
1811         str_replace:
1812           params:
1813             __rand_str__: { get_resource: random-str }
1814             # repo related
1815             __artifacts_version__: { get_param: artifacts_version }
1816             __docker_version__: { get_param: dcae_docker }
1817             __nexus_repo__: { get_param: nexus_repo }
1818             __nexus_docker_repo__: { get_param: nexus_docker_repo }
1819             __nexus_username__: { get_param: nexus_username }
1820             __nexus_password__: { get_param: nexus_password }
1821             # conf for the ONAP environment where the DCAE bootstrap vm/conatiner runs
1822             __dcae_deployment_profile__: { get_param: dcae_deployment_profile }
1823             __mac_addr__: { get_attr: [dcae_c_private_port, mac_address] }
1824             __dcae_ip_addr__: { get_param: dcae_ip_addr }
1825             __dcae_float_ip__: { get_attr: [dcae_c_floating_ip, floating_ip_address] }
1826             __dns_ip_addr__: { get_param: dns_ip_addr }
1827             __external_dns__: { get_param: external_dns }
1828             __dns_forwarder__: { get_param: dns_forwarder }
1829             __dcae_domain__: { get_param: dcae_domain }
1830             # conf for VMs DCAE is to bringup
1831             __openstack_keystone_url__: { get_param: keystone_url }
1832             __dcae_keystone_url__: { get_param: dcae_keystone_url }
1833             __dcaeos_cloud_env__: { get_param: cloud_env }
1834             __dcaeos_keystone_url__: { get_param: dcae_keystone_url }
1835             __dcaeos_region__: { get_param: openstack_region }
1836             __dcaeos_tenant_id__: { get_param: openstack_tenant_id }
1837             __dcaeos_tenant_name__: { get_param: openstack_tenant_name }
1838             __dcaeos_security_group__:
1839               str_replace:
1840                 template: 'onap_sg_rand'
1841                 params:
1842                   rand: { get_resource: random-str }
1843             #__dcaeos_security_group__: { get_attr: [onap_sg, name] }
1844             __dcaeos_username__: { get_param: openstack_username }
1845             __dcaeos_password__: { get_param: openstack_api_key }
1846             __dcaeos_key_name__: { get_resource: vm_key }
1847             __dcaeos_public_key__: { get_param: dcae_public_key }
1848             __dcaeos_private_key__: { get_param: dcae_private_key }
1849             __dcaeos_private_network_name__: { get_attr: [oam_onap, name] }
1850             __dcaeos_public_network_name__: { get_param: public_net_name }
1851             __dcaeos_ubuntu_1604_image__: { get_param: ubuntu_1604_image }
1852             __dcaeos_centos_7_image__: { get_param: dcae_centos_7_image }
1853             __dcaeos_flavor_id__: { get_param: flavor_medium }
1854             __dcaeos_flavor_id_cdap__: { get_param: flavor_large }
1855             __dcaeos_dnsaas_config_enabled__: { get_param: dnsaas_config_enabled }
1856             __dcaeos_dnsaas_region__: { get_param: dnsaas_region }
1857             __dcaeos_dnsaas_keystone_url__: { get_param: dnsaas_keystone_url }
1858             __dnsaas_tenant_name__: { get_param: dnsaas_tenant_name }
1859             __dcaeos_dnsaas_username__: { get_param: dnsaas_username }
1860             __dcaeos_dnsaas_password__: { get_param: dnsaas_password }
1861             # fixed private IPs
1862             __mr_ip_addr__: { get_param: mr_ip_addr }
1863             __policy_ip_addr__: { get_param: policy_ip_addr }
1864             __sdc_ip_addr__: { get_param: sdc_ip_addr }
1865             __openo_ip_addr__: { get_param: openo_ip_addr }
1866             __aai1_ip_addr__: { get_param: aai1_ip_addr }
1867             __aai2_ip_addr__: { get_param: aai2_ip_addr }
1868             # floating IPs
1869             __dns_floating_ip_addr__: { get_attr: [dns_floating_ip, floating_ip_address] }
1870             __aai1_floating_ip_addr__: { get_attr: [aai1_floating_ip, floating_ip_address] }
1871             __aai2_floating_ip_addr__: { get_attr: [aai2_floating_ip, floating_ip_address] }
1872             __mrouter_floating_ip_addr__: { get_attr: [mrouter_floating_ip, floating_ip_address] }
1873             __sdc_floating_ip_addr__: { get_attr: [sdc_floating_ip, floating_ip_address] }
1874             __policy_floating_ip_addr__: { get_attr: [policy_floating_ip, floating_ip_address] }
1875             __openo_floating_ip_addr__: { get_attr: [openo_floating_ip, floating_ip_address] }
1876             __dcae_c_floating_ip_addr__: { get_attr: [dcae_c_floating_ip, floating_ip_address] }
1877             # container versions
1878             __dcae_docker__:  { get_param: dcae_docker }
1879             __dcae_snmptrap_docker__:  { get_param: dcae_snmptrap_docker }
1880             __dcae_ves_docker__:  { get_param: dcae_ves_docker }
1881             __dcae_bootstrap_docker__:  { get_param: dcae_bootstrap_docker }
1882             __dcae_cm_docker__:  { get_param: dcae_cm_docker }
1883             __dcae_k8sbootstrap_docker__:  { get_param: dcae_k8sbootstrap_docker }
1884             __dcae_redisc_docker__:  { get_param: dcae_redisc_docker }
1885             __dcae_tca_docker__:  { get_param: dcae_tca_docker }
1886             __dcae_cb_docker__:  { get_param: dcae_cb_docker }
1887             __dcae_cbs_docker__:  { get_param: dcae_cbs_docker }
1888             __dcae_dh_docker__:  { get_param: dcae_dh_docker }
1889             __dcae_inv_docker__:  { get_param: dcae_inv_docker }
1890             __dcae_ph_docker__:  { get_param: dcae_ph_docker }
1891             __dcae_sch_docker__:  { get_param: dcae_sch_docker }
1892             __dcae_heartbeat_docker__:  { get_param: dcae_heartbeat_docker }
1893             __dcae_prh_docker__:  { get_param: dcae_prh_docker }
1894             __holmes_em_docker__:  { get_param: holmes_em_docker }
1895             __holmes_rm_docker__:  { get_param: holmes_rm_docker }
1896
1897
1898           template: |
1899             #!/bin/bash
1900
1901             # Create configuration files
1902             mkdir -p /opt/config
1903             echo "__rand_str__" > /opt/config/dcae_zone.txt
1904             echo "__rand_str__" > /opt/config/rand_str.txt
1905             # repo related
1906             echo "__docker_version__" > /opt/config/docker_version.txt
1907             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
1908             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
1909             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
1910             echo "__nexus_username__" > /opt/config/nexus_username.txt
1911             echo "__nexus_password__" > /opt/config/nexus_password.txt
1912             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
1913             # conf for the ONAP environment where the DCAE bootstrap vm/conatiner runs
1914             echo "__dcae_deployment_profile__" > /opt/config/dcae_deployment_profile.txt
1915             echo "__mac_addr__" > /opt/config/mac_addr.txt
1916             echo "__dcae_ip_addr__" > /opt/config/dcae_ip_addr.txt
1917             echo "__dcae_float_ip__" > /opt/config/dcae_float_ip.txt
1918             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
1919             echo "__external_dns__" > /opt/config/external_dns.txt
1920             echo "__dns_forwarder__" > /opt/config/dns_forwarder.txt
1921             echo "__dcae_domain__" > /opt/config/dcae_domain.txt
1922             # conf for the OpenStack env where DCAE is deployed
1923             echo "__openstack_keystone_url__" > /opt/config/openstack_keystone_url.txt
1924             echo "__dcaeos_cloud_env__" > /opt/config/cloud_env.txt
1925             echo "__dcaeos_keystone_url__" > /opt/config/keystone_url.txt
1926             echo "__dcaeos_region__" > /opt/config/openstack_region.txt
1927             echo "__dcaeos_tenant_id__" > /opt/config/tenant_id.txt
1928             echo "__dcaeos_tenant_name__" > /opt/config/tenant_name.txt
1929             echo "__dcaeos_username__" > /opt/config/openstack_user.txt
1930             echo "__dcaeos_password__" > /opt/config/openstack_password.txt
1931             echo "__dcaeos_key_name__" > /opt/config/key_name.txt
1932             echo "__dcaeos_public_key__" > /opt/config/pub_key.txt
1933             echo "__dcaeos_private_key__" > /opt/config/priv_key
1934             echo "__dcaeos_private_network_name__" > /opt/config/openstack_private_network_name.txt
1935             echo "__dcaeos_public_network_name__" > /opt/config/public_net_name.txt
1936             echo "__dcaeos_public_network_name__" > /opt/config/public_net_id.txt
1937             echo "__dcaeos_ubuntu_1604_image__" > /opt/config/ubuntu_1604_image.txt
1938             echo "__dcaeos_centos_7_image__" > /opt/config/centos_7_image.txt
1939             echo "__dcaeos_security_group__" > /opt/config/security_group.txt
1940             echo "__dcaeos_flavor_id__" > /opt/config/flavor_id.txt
1941             echo "__dcaeos_flavor_id_cdap__" > /opt/config/flavor_id_cdap.txt
1942             echo "__dcaeos_dnsaas_config_enabled__" > /opt/config/dnsaas_config_enabled.txt
1943             echo "__dcaeos_dnsaas_region__" > /opt/config/dnsaas_region.txt
1944             echo "__dcaeos_dnsaas_keystone_url__" > /opt/config/dnsaas_keystone_url.txt
1945             echo "__dnsaas_tenant_name__" > /opt/config/dnsaas_tenant_name.txt
1946             echo "__dcaeos_dnsaas_username__" > /opt/config/dnsaas_username.txt
1947             echo "__dcaeos_dnsaas_password__" > /opt/config/dnsaas_password.txt
1948             # fixed private IP addresses of other ONAP components
1949             echo "__mr_ip_addr__" > /opt/config/mr_ip_addr.txt
1950             echo "__policy_ip_addr__" > /opt/config/policy_ip_addr.txt
1951             echo "__sdc_ip_addr__" > /opt/config/sdc_ip_addr.txt
1952             echo "__openo_ip_addr__" > /opt/config/openo_ip_addr.txt
1953             echo "__openo_ip_addr__" > /opt/config/msb_ip_addr.txt
1954             echo "__aai1_ip_addr__" > /opt/config/aai1_ip_addr.txt
1955             echo "__aai2_ip_addr__" > /opt/config/aai2_ip_addr.txt
1956             # floating IPs
1957             echo "__dns_floating_ip_addr__" > /opt/config/dns_floating_ip_addr.txt
1958             echo "__aai1_floating_ip_addr__" > /opt/config/aai1_floating_ip_addr.txt
1959             echo "__aai2_floating_ip_addr__" > /opt/config/aai2_floating_ip_addr.txt
1960             echo "__mrouter_floating_ip_addr__" > /opt/config/mrouter_floating_ip_addr.txt
1961             echo "__sdc_floating_ip_addr__" > /opt/config/sdc_floating_ip_addr.txt
1962             echo "__policy_floating_ip_addr__" > /opt/config/policy_floating_ip_addr.txt
1963             echo "__openo_floating_ip_addr__" > /opt/config/openo_floating_ip_addr.txt
1964             echo "__dcae_c_floating_ip_addr__" > /opt/config/dcae_c_floating_ip_addr.txt
1965             # container versions
1966             echo "__dcae_docker__" > /opt/config/dcae_docker.txt
1967             echo "__dcae_snmptrap_docker__" > /opt/config/dcae_docker_snmptrap.txt
1968             echo "__dcae_ves_docker__" > /opt/config/dcae_docker_ves.txt
1969             echo "__dcae_bootstrap_docker__" > /opt/config/dcae_docker_bootstrap.txt
1970             echo "__dcae_cm_docker__" > /opt/config/dcae_docker_cm.txt
1971             echo "__dcae_k8sbootstrap_docker__" > /opt/config/dcae_docker_k8sbootstrap.txt
1972             echo "__dcae_redisc_docker__" > /opt/config/dcae_docker_redisc.txt
1973             echo "__dcae_tca_docker__" > /opt/config/dcae_docker_tca.txt
1974             echo "__dcae_cb_docker__" > /opt/config/dcae_docker_cb.txt
1975             echo "__dcae_cbs_docker__" > /opt/config/dcae_docker_cbs.txt
1976             echo "__dcae_dh_docker__" > /opt/config/dcae_docker_dh.txt
1977             echo "__dcae_inv_docker__" > /opt/config/dcae_docker_inv.txt
1978             echo "__dcae_ph_docker__" > /opt/config/dcae_docker_ph.txt
1979             echo "__dcae_sch_docker__" > /opt/config/dcae_docker_sch.txt
1980             echo "__dcae_heartbeat_docker__" > /opt/config/dcae_docker_heartbeat.txt
1981             echo "__dcae_prh_docker__" > /opt/config/dcae_docker_prh.txt
1982             echo "__holmes_em_docker__" > /opt/config/holmes_docker_em.txt
1983             echo "__holmes_rm_docker__" > /opt/config/holmes_docker_rm.txt
1984
1985             # Download and run install script
1986             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/dcae2_install.sh -o /opt/dcae2_install.sh
1987             cd /opt
1988             chmod +x dcae2_install.sh
1989             ./dcae2_install.sh > /tmp/dcae2_install.log 2>&1
1990
1991
1992   # MUSIC instantiation
1993   music_private_port:
1994     type: OS::Neutron::Port
1995     properties:
1996       network: { get_resource: oam_onap }
1997       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: music_ip_addr }}]
1998       security_groups:
1999       - { get_resource: onap_sg }
2000
2001   music_floating_ip:
2002     type: OS::Neutron::FloatingIP
2003     properties:
2004       floating_network_id: { get_param: public_net_id }
2005       port_id: { get_resource: music_private_port }
2006
2007   music_vm:
2008     type: OS::Nova::Server
2009     properties:
2010       image: { get_param: ubuntu_1404_image }
2011       flavor: { get_param: flavor_large }
2012       name:
2013         str_replace:
2014           template: base-music
2015           params:
2016             base: { get_param: vm_base_name }
2017       key_name: { get_resource: vm_key }
2018       networks:
2019         - port: { get_resource: music_private_port }
2020       user_data_format: RAW
2021       user_data:
2022         str_replace:
2023           params:
2024             __nexus_repo__: { get_param: nexus_repo }
2025             __nexus_docker_repo__: { get_param: nexus_docker_repo }
2026             __nexus_username__: { get_param: nexus_username }
2027             __nexus_password__: { get_param: nexus_password }
2028             __artifacts_version__: { get_param: artifacts_version }
2029             __dns_ip_addr__: { get_param: dns_ip_addr }
2030             __docker_version__: { get_param: music_docker }
2031             __music_repo__: { get_param: music_repo }
2032             __gerrit_branch__: { get_param: music_branch }
2033             __cloud_env__: { get_param: cloud_env }
2034             __external_dns__: { get_param: external_dns }
2035           template: |
2036             #!/bin/bash
2037
2038             # Create configuration files
2039             mkdir -p /opt/config
2040             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
2041             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
2042             echo "__nexus_username__" > /opt/config/nexus_username.txt
2043             echo "__nexus_password__" > /opt/config/nexus_password.txt
2044             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
2045             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
2046             echo "__docker_version__" > /opt/config/docker_version.txt
2047             echo "__music_repo__" > /opt/config/remote_repo.txt
2048             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
2049             echo "__cloud_env__" > /opt/config/cloud_env.txt
2050             echo "__external_dns__" > /opt/config/external_dns.txt
2051
2052             # Download and run install script
2053             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/music_install.sh -o /opt/music_install.sh
2054             cd /opt
2055             chmod +x music_install.sh
2056             ./music_install.sh
2057
2058
2059   # OOF instantiation
2060   oof_private_port:
2061     type: OS::Neutron::Port
2062     properties:
2063       network: { get_resource: oam_onap }
2064       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: oof_ip_addr }}]
2065       security_groups:
2066       - { get_resource: onap_sg }
2067
2068   oof_floating_ip:
2069     type: OS::Neutron::FloatingIP
2070     properties:
2071       floating_network_id: { get_param: public_net_id }
2072       port_id: { get_resource: oof_private_port }
2073
2074   oof_vm:
2075     type: OS::Nova::Server
2076     properties:
2077       image: { get_param: ubuntu_1604_image }
2078       flavor: { get_param: flavor_large }
2079       name:
2080         str_replace:
2081           template: base-oof
2082           params:
2083             base: { get_param: vm_base_name }
2084       key_name: { get_resource: vm_key }
2085       networks:
2086         - port: { get_resource: oof_private_port }
2087       user_data_format: RAW
2088       user_data:
2089         str_replace:
2090           params:
2091             __nexus_repo__: { get_param: nexus_repo }
2092             __nexus_docker_repo__: { get_param: nexus_docker_repo }
2093             __nexus_username__: { get_param: nexus_username }
2094             __nexus_password__: { get_param: nexus_password }
2095             __artifacts_version__: { get_param: artifacts_version }
2096             __dns_ip_addr__: { get_param: dns_ip_addr }
2097             __docker_version__: { get_param: oof_docker }
2098             __oof_repo__: { get_param: oof_repo }
2099             __gerrit_branch__: { get_param: oof_branch }
2100             __cloud_env__: { get_param: cloud_env }
2101             __external_dns__: { get_param: external_dns }
2102           template: |
2103             #!/bin/bash
2104
2105             # Create configuration files
2106             mkdir -p /opt/config
2107             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
2108             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
2109             echo "__nexus_username__" > /opt/config/nexus_username.txt
2110             echo "__nexus_password__" > /opt/config/nexus_password.txt
2111             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
2112             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
2113             echo "__docker_version__" > /opt/config/docker_version.txt
2114             echo "__oof_repo__" > /opt/config/remote_repo.txt
2115             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
2116             echo "__cloud_env__" > /opt/config/cloud_env.txt
2117             echo "__external_dns__" > /opt/config/external_dns.txt
2118
2119             # Download and run install script
2120             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/oof_install.sh -o /opt/oof_install.sh
2121             cd /opt
2122             chmod +x oof_install.sh
2123             ./oof_install.sh
2124
2125
2126   # AAF instantiation
2127   aaf_private_port:
2128     type: OS::Neutron::Port
2129     properties:
2130       network: { get_resource: oam_onap }
2131       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: aaf_ip_addr }}]
2132       security_groups:
2133       - { get_resource: onap_sg }
2134
2135   aaf_floating_ip:
2136     type: OS::Neutron::FloatingIP
2137     properties:
2138       floating_network_id: { get_param: public_net_id }
2139       port_id: { get_resource: aaf_private_port }
2140
2141   aaf_vm:
2142     type: OS::Nova::Server
2143     properties:
2144       image: { get_param: ubuntu_1604_image }
2145       flavor: { get_param: flavor_medium }
2146       name:
2147         str_replace:
2148           template: base-aaf
2149           params:
2150             base: { get_param: vm_base_name }
2151       key_name: { get_resource: vm_key }
2152       networks:
2153         - port: { get_resource: aaf_private_port }
2154       user_data_format: RAW
2155       user_data:
2156         str_replace:
2157           params:
2158             __nexus_repo__: { get_param: nexus_repo }
2159             __nexus_docker_repo__: { get_param: nexus_docker_repo }
2160             __nexus_username__: { get_param: nexus_username }
2161             __nexus_password__: { get_param: nexus_password }
2162             __artifacts_version__: { get_param: artifacts_version }
2163             __dns_ip_addr__: { get_param: dns_ip_addr }
2164             __docker_version__: { get_param: aaf_docker }
2165             __cloud_env__: { get_param: cloud_env }
2166             __external_dns__: { get_param: external_dns }
2167             __aaf_repo__: { get_param: aaf_repo }
2168             __gerrit_branch__: { get_param: aaf_branch }
2169             __local_ip__: { get_param: aaf_ip_addr }
2170           template: |
2171             #!/bin/bash
2172
2173             # Create configuration files
2174             mkdir -p /opt/config
2175             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
2176             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
2177             echo "__nexus_username__" > /opt/config/nexus_username.txt
2178             echo "__nexus_password__" > /opt/config/nexus_password.txt
2179             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
2180             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
2181             echo "__docker_version__" > /opt/config/docker_version.txt
2182             echo "__cloud_env__" > /opt/config/cloud_env.txt
2183             echo "__external_dns__" > /opt/config/external_dns.txt
2184             echo "__aaf_repo__" > /opt/config/remote_repo.txt
2185             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
2186             echo "__local_ip__" > /opt/config/local_ip.txt
2187
2188             # Download and run install script
2189             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/aaf_install.sh -o /opt/aaf_install.sh
2190             cd /opt
2191             chmod +x aaf_install.sh
2192             ./aaf_install.sh
2193
2194   # SMS instantiation
2195   sms_private_port:
2196     type: OS::Neutron::Port
2197     properties:
2198       network: { get_resource: oam_onap }
2199       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: sms_ip_addr }}]
2200       security_groups:
2201       - { get_resource: onap_sg }
2202
2203   sms_floating_ip:
2204     type: OS::Neutron::FloatingIP
2205     properties:
2206       floating_network_id: { get_param: public_net_id }
2207       port_id: { get_resource: sms_private_port }
2208
2209   sms_vm:
2210     type: OS::Nova::Server
2211     properties:
2212       image: { get_param: ubuntu_1604_image }
2213       flavor: { get_param: flavor_medium }
2214       name:
2215         str_replace:
2216           template: base-sms
2217           params:
2218             base: { get_param: vm_base_name }
2219       key_name: { get_resource: vm_key }
2220       networks:
2221         - port: { get_resource: sms_private_port }
2222       user_data_format: RAW
2223       user_data:
2224         str_replace:
2225           params:
2226             __nexus_repo__: { get_param: nexus_repo }
2227             __nexus_docker_repo__: { get_param: nexus_docker_repo }
2228             __nexus_username__: { get_param: nexus_username }
2229             __nexus_password__: { get_param: nexus_password }
2230             __artifacts_version__: { get_param: artifacts_version }
2231             __dns_ip_addr__: { get_param: dns_ip_addr }
2232             __docker_version__: { get_param: sms_docker }
2233             __cloud_env__: { get_param: cloud_env }
2234             __external_dns__: { get_param: external_dns }
2235             __sms_repo__: { get_param: sms_repo }
2236             __gerrit_branch__: { get_param: sms_branch }
2237             __local_ip__: { get_param: sms_ip_addr }
2238           template: |
2239             #!/bin/bash
2240
2241             # Create configuration files
2242             mkdir -p /opt/config
2243             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
2244             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
2245             echo "__nexus_username__" > /opt/config/nexus_username.txt
2246             echo "__nexus_password__" > /opt/config/nexus_password.txt
2247             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
2248             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
2249             echo "__docker_version__" > /opt/config/docker_version.txt
2250             echo "__cloud_env__" > /opt/config/cloud_env.txt
2251             echo "__external_dns__" > /opt/config/external_dns.txt
2252             echo "__sms_repo__" > /opt/config/remote_repo.txt
2253             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
2254             echo "__local_ip__" > /opt/config/local_ip.txt
2255
2256             # Download and run install script
2257             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/sms_install.sh -o /opt/sms_install.sh
2258             cd /opt
2259             chmod +x sms_install.sh
2260             ./sms_install.sh
2261
2262   # NBI instantiation
2263   nbi_private_port:
2264     type: OS::Neutron::Port
2265     properties:
2266       network: { get_resource: oam_onap }
2267       fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: nbi_ip_addr }}]
2268       security_groups:
2269       - { get_resource: onap_sg }
2270
2271   nbi_floating_ip:
2272     type: OS::Neutron::FloatingIP
2273     properties:
2274       floating_network_id: { get_param: public_net_id }
2275       port_id: { get_resource: nbi_private_port }
2276
2277   nbi_vm:
2278     type: OS::Nova::Server
2279     properties:
2280       image: { get_param: ubuntu_1604_image }
2281       flavor: { get_param: flavor_small }
2282       name:
2283         str_replace:
2284           template: base-nbi
2285           params:
2286             base: { get_param: vm_base_name }
2287       key_name: { get_resource: vm_key }
2288       networks:
2289         - port: { get_resource: nbi_private_port }
2290       user_data_format: RAW
2291       user_data:
2292         str_replace:
2293           params:
2294             __nexus_repo__: { get_param: nexus_repo }
2295             __nexus_docker_repo__: { get_param: nexus_docker_repo }
2296             __nexus_username__: { get_param: nexus_username }
2297             __nexus_password__: { get_param: nexus_password }
2298             __artifacts_version__: { get_param: artifacts_version }
2299             __dns_ip_addr__: { get_param: dns_ip_addr }
2300             __docker_version__: { get_param: nbi_docker }
2301             __nbi_repo__: { get_param: nbi_repo }
2302             __gerrit_branch__: { get_param: nbi_branch }
2303             __cloud_env__: { get_param: cloud_env }
2304             __external_dns__: { get_param: external_dns }
2305             __sdc_ip_addr__: { get_param: sdc_ip_addr }
2306             __aai1_ip_addr__: { get_param: aai1_ip_addr }
2307             __so_ip_addr__: { get_param: so_ip_addr }
2308           template: |
2309             #!/bin/bash
2310
2311             # Create configuration files
2312             mkdir -p /opt/config
2313             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
2314             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
2315             echo "__nexus_username__" > /opt/config/nexus_username.txt
2316             echo "__nexus_password__" > /opt/config/nexus_password.txt
2317             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
2318             echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
2319             echo "__docker_version__" > /opt/config/docker_version.txt
2320             echo "__nbi_repo__" > /opt/config/remote_repo.txt
2321             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
2322             echo "__cloud_env__" > /opt/config/cloud_env.txt
2323             echo "__external_dns__" > /opt/config/external_dns.txt
2324             echo "__sdc_ip_addr__" > /opt/config/sdc_ip_addr.txt
2325             echo "__aai1_ip_addr__" > /opt/config/aai_ip_addr.txt
2326             echo "__so_ip_addr__" > /opt/config/so_ip_addr.txt
2327
2328             # Download and run install script
2329             curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/nbi_install.sh -o /opt/nbi_install.sh
2330             cd /opt
2331             chmod +x nbi_install.sh
2332             ./nbi_install.sh