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