Update INFO.yaml with new PTL
[demo.git] / heat / OpenECOMP / onap_rackspace.yaml
1 heat_template_version: 2013-05-23
2
3 description: Heat template to deploy ONAP components
4
5 parameters:
6
7   # Generic parameters used across all ONAP components
8   public_net_id:
9     type: string
10     description: Public network that enables remote connection to the compute instance
11
12   key_name:
13     type: string
14     description: Public/Private key pair name
15
16   pub_key:
17     type: string
18     description: Public key or SSL certificate to be installed on the compute instance
19
20   nexus_repo:
21     type: string
22     description: Complete URL for the Nexus repository.
23
24   nexus_docker_repo:
25     type: string
26     description: Complete URL for the Nexus repository for docker images.
27
28   nexus_username:
29     type: string
30     description: Nexus Repository username
31
32   nexus_password:
33     type: string
34     description: Nexus Repository Password
35
36   openstack_tenant_id:
37     type: string
38     description: Rackspace tenant ID
39
40   openstack_username:
41     type: string
42     description: Rackspace username
43
44   openstack_api_key:
45     type: string
46     description: Rackspace API Key
47
48   openstack_password:
49     type: string
50     description: Rackspace Password
51
52   openstack_auth_method:
53     type: string
54     description: Openstack authentication method (password VS. api-key)
55
56   dmaap_topic:
57     type: string
58     description: DMaaP topic name
59
60   artifacts_version:
61     type: string
62     description: Artifacts version of ONAP components
63
64   docker_version:
65     type: string
66     description: Docker version of ONAP docker images
67
68   gerrit_branch:
69     type: string
70     description: Gerrit branch where to download the code from
71
72   cloud_env:
73     type: string
74     description: Cloud Provider Name
75
76
77   # Parameters for DCAE instantiation
78   dcae_base_environment:
79     type: string
80     description: DCAE Base Environment configuration (RACKSPACE/2-NIC/...)
81
82   dcae_zone:
83     type: string
84     description: DCAE Zone to use in VM names created by DCAE controller
85
86   dcae_state:
87     type: string
88     description: DCAE State to use in VM names created by DCAE controller
89
90   nexus_repo_root:
91     type: string
92     description: Root URL of nexus repository
93
94   nexus_url_snapshot:
95     type: string
96     description: Snapshot of Maven repository
97
98   openstack_region:
99     type: string
100     description: Rackspace region where the DCAE controller will spin the VMs
101
102   gitlab_branch:
103     type: string
104     description: Branch of the Gitlab repository
105
106   dcae_code_version:
107     type: string
108     description: DCAE Code Version Number
109
110   dcae_ip_addr:
111     type: string
112     description: DCAE IP Address
113  
114   dcae_coll_ip_addr:
115     type: string
116     description: DCAE Collector IP Address
117
118   dcae_db_ip_addr:
119     type: string
120     description: DCAE Database IP Address
121
122   dcae_hdp1_ip_addr:
123     type: string
124     description: Hadoop VM1 IP Address
125
126   dcae_hdp2_ip_addr:
127     type: string
128     description: Hadoop VM2 IP Address
129
130   dcae_hdp3_ip_addr:
131     type: string
132     description: Hadoop VM3 IP Address
133
134
135 resources:
136   random-str:
137     type: OS::Heat::RandomString
138     properties:
139       length: 4
140
141   # Public key used to access ONAP components
142   vm_key:
143     type: OS::Nova::KeyPair
144     properties:
145       name:
146         str_replace:
147           template: base_rand
148           params:
149             base: { get_param: key_name }
150             rand: { get_resource: random-str }
151       public_key: { get_param: pub_key }
152       save_private_key: false
153
154
155   # ONAP management private network
156   oam_ecomp:
157     type: OS::Neutron::Net
158     properties:
159       name:
160         str_replace:
161           template: oam_ecomp_rand
162           params:
163             rand: { get_resource: random-str }
164
165   oam_ecomp_subnet:
166     type: OS::Neutron::Subnet
167     properties:
168       name:
169         str_replace:
170           template: oam_ecomp_rand
171           params:
172             rand: { get_resource: random-str }
173       network_id: { get_resource: oam_ecomp }
174       cidr: 10.0.0.0/8
175
176
177   # DNS Server instantiation
178   dns_private_port:
179     type: OS::Neutron::Port
180     properties:
181       network: { get_resource: oam_ecomp }
182       fixed_ips: [{"subnet": { get_resource: oam_ecomp_subnet }, "ip_address": 10.0.0.1}]
183
184   dns_vm:
185     type: OS::Nova::Server
186     properties:
187       image: Ubuntu 14.04 LTS (Trusty Tahr) (PVHVM)
188       flavor: 4 GB General Purpose v1
189       name: vm1-dns-server
190       key_name: { get_resource: vm_key }
191       networks:
192         - network: { get_param: public_net_id }
193         - port: { get_resource: dns_private_port }
194       user_data_format: RAW
195       user_data:
196         str_replace:
197           params:
198             __nexus_repo__: { get_param: nexus_repo }
199             __artifacts_version__: { get_param: artifacts_version }
200             __cloud_env__: { get_param: cloud_env }
201           template: |
202             #!/bin/bash
203
204             # Create configuration files
205             mkdir -p /opt/config
206             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
207             echo "__cloud_env__" > /opt/config/cloud_env.txt
208             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
209
210             # Download and run install script
211             curl -k __nexus_repo__/org.openecomp.demo/boot/__artifacts_version__/dns_install.sh -o /opt/dns_install.sh
212             cd /opt
213             chmod +x dns_install.sh
214             ./dns_install.sh
215
216
217   # A&AI instantiation
218   aai_private_port:
219     type: OS::Neutron::Port
220     properties:
221       network: { get_resource: oam_ecomp }
222       fixed_ips: [{"subnet": { get_resource: oam_ecomp_subnet }, "ip_address": 10.0.1.1}]
223
224   aai_volume:
225     type: OS::Cinder::Volume
226     properties:
227       name: vol1-aai
228       size: 50
229       volume_type: SSD
230       image: Ubuntu 14.04 LTS (Trusty Tahr) (PVHVM)
231
232   aai_vm:
233     type: OS::Nova::Server
234     properties:
235       flavor: 15 GB Compute v1
236       name: vm1-aai
237       key_name: { get_resource: vm_key }
238       block_device_mapping:
239         - volume_id: { get_resource: aai_volume }
240           device_name: vda
241       networks:
242         - network: { get_param: public_net_id }
243         - port: { get_resource: aai_private_port }
244       user_data_format: RAW
245       user_data:
246         str_replace:
247           params:
248             __nexus_repo__: { get_param: nexus_repo }
249             __nexus_docker_repo__: { get_param: nexus_docker_repo }
250             __nexus_username__: { get_param: nexus_username }
251             __nexus_password__: { get_param: nexus_password }
252             __dmaap_topic__: { get_param: dmaap_topic }
253             __artifacts_version__: { get_param: artifacts_version }
254             __docker_version__: { get_param: docker_version }
255             __cloud_env__: { get_param: cloud_env }
256           template: |
257             #!/bin/bash
258
259             # Create configuration files
260             mkdir -p /opt/config
261             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
262             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
263             echo "__nexus_username__" > /opt/config/nexus_username.txt
264             echo "__nexus_password__" > /opt/config/nexus_password.txt
265             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
266             echo "10.0.0.1" > /opt/config/dns_ip_addr.txt
267             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
268             echo "__docker_version__" > /opt/config/docker_version.txt
269             echo "__cloud_env__" > /opt/config/cloud_env.txt
270
271             # Download and run install script
272             curl -k __nexus_repo__/org.openecomp.demo/boot/__artifacts_version__/aai_install.sh -o /opt/aai_install.sh
273             cd /opt
274             chmod +x aai_install.sh
275             ./aai_install.sh
276
277
278   # MSO instantiation
279   mso_private_port:
280     type: OS::Neutron::Port
281     properties:
282       network: { get_resource: oam_ecomp }
283       fixed_ips: [{"subnet": { get_resource: oam_ecomp_subnet }, "ip_address": 10.0.5.1}]
284
285   mso_vm:
286     type: OS::Nova::Server
287     properties:
288       image: Ubuntu 16.04 LTS (Xenial Xerus) (PVHVM)
289       flavor: 4 GB General Purpose v1
290       name: vm1-mso
291       key_name: { get_resource: vm_key }
292       networks:
293         - network: { get_param: public_net_id }
294         - port: { get_resource: mso_private_port }
295       user_data_format: RAW
296       user_data:
297         str_replace:
298           params:
299             __nexus_repo__: { get_param: nexus_repo }
300             __nexus_docker_repo__: { get_param: nexus_docker_repo }
301             __nexus_username__: { get_param: nexus_username }
302             __nexus_password__: { get_param: nexus_password }
303             __openstack_username__: { get_param: openstack_username }
304             __openstack_tenant_id__: { get_param: openstack_tenant_id }
305             __openstack_api_key__: { get_param: openstack_api_key }
306             __dmaap_topic__: { get_param: dmaap_topic }
307             __artifacts_version__: { get_param: artifacts_version }
308             __docker_version__: { get_param: docker_version }
309             __gerrit_branch__: { get_param: gerrit_branch }
310             __cloud_env__: { get_param: cloud_env }
311           template: |
312             #!/bin/bash
313
314             # Create configuration files
315             mkdir -p /opt/config
316             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
317             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
318             echo "__nexus_username__" > /opt/config/nexus_username.txt
319             echo "__nexus_password__" > /opt/config/nexus_password.txt
320             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
321             echo "10.0.0.1" > /opt/config/dns_ip_addr.txt
322             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
323             echo "__openstack_username__" > /opt/config/openstack_username.txt
324             echo "__openstack_tenant_id__" > /opt/config/tenant_id.txt
325             echo "__openstack_api_key__" > /opt/config/openstack_api_key.txt
326             echo "__docker_version__" > /opt/config/docker_version.txt
327             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
328             echo "__cloud_env__" > /opt/config/cloud_env.txt
329
330             # Download and run install script
331             curl -k __nexus_repo__/org.openecomp.demo/boot/__artifacts_version__/mso_install.sh -o /opt/mso_install.sh
332             cd /opt
333             chmod +x mso_install.sh
334             ./mso_install.sh
335
336
337   # Message Router instantiation
338   mrouter_private_port:
339     type: OS::Neutron::Port
340     properties:
341       network: { get_resource: oam_ecomp }
342       fixed_ips: [{"subnet": { get_resource: oam_ecomp_subnet }, "ip_address": 10.0.11.1}]
343
344   mrouter_vm:
345     type: OS::Nova::Server
346     properties:
347       image: Ubuntu 14.04 LTS (Trusty Tahr) (PVHVM)
348       flavor: 15 GB I/O v1
349       name: vm1-message-router
350       key_name: { get_resource: vm_key }
351       networks:
352         - network: { get_param: public_net_id }
353         - port: { get_resource: mrouter_private_port }
354       user_data_format: RAW
355       user_data:
356         str_replace:
357           params:
358             __nexus_repo__: { get_param: nexus_repo }
359             __nexus_docker_repo__: { get_param: nexus_docker_repo }
360             __nexus_username__: { get_param: nexus_username }
361             __nexus_password__: { get_param: nexus_password }
362             __artifacts_version__: { get_param: artifacts_version }
363             __gerrit_branch__: { get_param: gerrit_branch }
364             __cloud_env__: { get_param: cloud_env }
365           template: |
366             #!/bin/bash
367
368             # Create configuration files
369             mkdir -p /opt/config
370             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
371             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
372             echo "__nexus_username__" > /opt/config/nexus_username.txt
373             echo "__nexus_password__" > /opt/config/nexus_password.txt
374             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
375             echo "10.0.0.1" > /opt/config/dns_ip_addr.txt
376             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
377             echo "__cloud_env__" > /opt/config/cloud_env.txt
378
379             # Download and run install script
380             curl -k __nexus_repo__/org.openecomp.demo/boot/__artifacts_version__/mr_install.sh -o /opt/mr_install.sh
381             cd /opt
382             chmod +x mr_install.sh
383             ./mr_install.sh
384
385
386   # RobotE2E instantiation
387   robot_private_port:
388     type: OS::Neutron::Port
389     properties:
390       network: { get_resource: oam_ecomp }
391       fixed_ips: [{"subnet": { get_resource: oam_ecomp_subnet }, "ip_address": 10.0.10.1}]
392
393   robot_vm:
394     type: OS::Nova::Server
395     properties:
396       image: Ubuntu 16.04 LTS (Xenial Xerus) (PVHVM)
397       flavor: 2 GB General Purpose v1
398       name: vm1-robot
399       key_name: { get_resource: vm_key }
400       networks:
401         - network: { get_param: public_net_id }
402         - port: { get_resource: robot_private_port }
403       user_data_format: RAW
404       user_data:
405         str_replace:
406           params:
407             __nexus_repo__: { get_param: nexus_repo }
408             __nexus_docker_repo__: { get_param: nexus_docker_repo }
409             __nexus_username__: { get_param: nexus_username }
410             __nexus_password__: { get_param: nexus_password }
411             __network_name__: { get_attr: [oam_ecomp, name] }
412             __openstack_username__: { get_param: openstack_username }
413             __openstack_api_key__: { get_param : openstack_api_key }
414             __openstack_password__: { get_param: openstack_password }
415             __artifacts_version__: { get_param: artifacts_version }
416             __openstack_region__: { get_param: openstack_region }
417             __docker_version__: { get_param: docker_version }
418             __gerrit_branch__: { get_param: gerrit_branch }
419             __cloud_env__: { get_param: cloud_env }
420           template: |
421             #!/bin/bash
422
423             # Create configuration files
424             mkdir -p /opt/config
425             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
426             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
427             echo "__nexus_username__" > /opt/config/nexus_username.txt
428             echo "__nexus_password__" > /opt/config/nexus_password.txt
429             echo "__network_name__" > /opt/config/network.txt
430             echo "__openstack_username__" > /opt/config/openstack_username.txt
431             echo "__openstack_password__" > /opt/config/openstack_password.txt
432             echo "__openstack_api_key__" > /opt/config/openstack_api_key.txt
433             echo "__openstack_region__" > /opt/config/region.txt
434             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
435             echo "__docker_version__" > /opt/config/docker_version.txt
436             echo "10.0.0.1" > /opt/config/dns_ip_addr.txt
437             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
438             echo "__cloud_env__" > /opt/config/cloud_env.txt
439
440             # Download and run install script
441             curl -k __nexus_repo__/org.openecomp.demo/boot/__artifacts_version__/robot_install.sh -o /opt/robot_install.sh
442             cd /opt
443             chmod +x robot_install.sh
444             ./robot_install.sh
445
446
447   # VID instantiation
448   vid_private_port:
449     type: OS::Neutron::Port
450     properties:
451       network: { get_resource: oam_ecomp }
452       fixed_ips: [{"subnet": { get_resource: oam_ecomp_subnet }, "ip_address": 10.0.8.1}]
453
454   vid_vm:
455     type: OS::Nova::Server
456     properties:
457       image: Ubuntu 14.04 LTS (Trusty Tahr) (PVHVM)
458       flavor: 2 GB General Purpose v1
459       name: vm1-vid
460       key_name: { get_resource: vm_key }
461       networks:
462         - network: { get_param: public_net_id }
463         - port: { get_resource: vid_private_port }
464       user_data_format: RAW
465       user_data:
466         str_replace:
467           params:
468             __nexus_repo__: { get_param: nexus_repo }
469             __nexus_docker_repo__: { get_param: nexus_docker_repo }
470             __nexus_username__: { get_param: nexus_username }
471             __nexus_password__: { get_param: nexus_password }
472             __artifacts_version__: { get_param: artifacts_version }
473             __docker_version__: { get_param: docker_version }
474             __gerrit_branch__: { get_param: gerrit_branch }
475             __cloud_env__: { get_param: cloud_env }
476           template: |
477             #!/bin/bash
478
479             # Create configuration files
480             mkdir -p /opt/config
481             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
482             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
483             echo "__nexus_username__" > /opt/config/nexus_username.txt
484             echo "__nexus_password__" > /opt/config/nexus_password.txt
485             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
486             echo "10.0.0.1" > /opt/config/dns_ip_addr.txt
487             echo "__docker_version__" > /opt/config/docker_version.txt
488             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
489             echo "__cloud_env__" > /opt/config/cloud_env.txt
490
491             # Download and run install script
492             curl -k __nexus_repo__/org.openecomp.demo/boot/__artifacts_version__/vid_install.sh -o /opt/vid_install.sh
493             cd /opt
494             chmod +x vid_install.sh
495             ./vid_install.sh
496
497
498   # SDN-C instantiation
499   sdnc_private_port:
500     type: OS::Neutron::Port
501     properties:
502       network: { get_resource: oam_ecomp }
503       fixed_ips: [{"subnet": { get_resource: oam_ecomp_subnet }, "ip_address": 10.0.7.1}]
504
505   sdnc_vm:
506     type: OS::Nova::Server
507     properties:
508       image: Ubuntu 14.04 LTS (Trusty Tahr) (PVHVM)
509       flavor: 4 GB General Purpose v1
510       name: vm1-sdnc
511       key_name: { get_resource: vm_key }
512       networks:
513         - network: { get_param: public_net_id }
514         - port: { get_resource: sdnc_private_port }
515       user_data_format: RAW
516       user_data:
517         str_replace:
518           params:
519             __nexus_repo__: { get_param: nexus_repo }
520             __nexus_docker_repo__: { get_param: nexus_docker_repo }
521             __nexus_username__: { get_param: nexus_username }
522             __nexus_password__: { get_param: nexus_password }
523             __artifacts_version__: { get_param: artifacts_version }
524             __docker_version__: { get_param: docker_version }
525             __gerrit_branch__: { get_param: gerrit_branch }
526             __cloud_env__: { get_param: cloud_env }
527           template: |
528             #!/bin/bash
529
530             # Create configuration files
531             mkdir -p /opt/config
532             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
533             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
534             echo "__nexus_username__" > /opt/config/nexus_username.txt
535             echo "__nexus_password__" > /opt/config/nexus_password.txt
536             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
537             echo "10.0.0.1" > /opt/config/dns_ip_addr.txt
538             echo "__docker_version__" > /opt/config/docker_version.txt
539             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
540             echo "__cloud_env__" > /opt/config/cloud_env.txt
541
542             # Download and run install script
543             curl -k __nexus_repo__/org.openecomp.demo/boot/__artifacts_version__/sdnc_install.sh -o /opt/sdnc_install.sh
544             cd /opt
545             chmod +x sdnc_install.sh
546             ./sdnc_install.sh
547
548
549   # SDC instantiation
550   sdc_private_port:
551     type: OS::Neutron::Port
552     properties:
553       network: { get_resource: oam_ecomp }
554       fixed_ips: [{"subnet": { get_resource: oam_ecomp_subnet }, "ip_address": 10.0.3.1}]
555
556   sdc_volume_local:
557     type: OS::Cinder::Volume
558     properties:
559       name: vol1-sdc-local
560       size: 50
561       volume_type: SSD
562       image: Ubuntu 16.04 LTS (Xenial Xerus) (PVHVM)
563
564   sdc_volume_data:
565     type: OS::Cinder::Volume
566     properties:
567       name: vol1-sdc-data
568       size: 100
569       volume_type: SSD
570
571   sdc_volume_attachment:
572     type: OS::Cinder::VolumeAttachment
573     properties:
574       volume_id: { get_resource: sdc_volume_data }
575       instance_uuid: { get_resource: sdc_vm }
576       mountpoint: /dev/xvdb
577
578   sdc_vm:
579     type: OS::Nova::Server
580     properties:
581       flavor: 15 GB Compute v1
582       name: vm1-sdc
583       key_name: { get_resource: vm_key }
584       block_device_mapping:
585         - volume_id: { get_resource: sdc_volume_local }
586           device_name: vda
587       networks:
588         - network: { get_param: public_net_id }
589         - port: { get_resource: sdc_private_port }
590       user_data_format: RAW
591       user_data:
592         str_replace:
593           params:
594             __nexus_repo__: { get_param: nexus_repo }
595             __nexus_docker_repo__: { get_param: nexus_docker_repo }
596             __nexus_username__: { get_param: nexus_username }
597             __nexus_password__: { get_param: nexus_password }
598             __env_name__: { get_param: dmaap_topic }
599             __artifacts_version__: { get_param: artifacts_version }
600             __docker_version__: { get_param: docker_version }
601             __gerrit_branch__: { get_param: gerrit_branch }
602             __cloud_env__: { get_param: cloud_env }
603           template: |
604             #!/bin/bash
605
606             # Create configuration files
607             mkdir -p /opt/config
608             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
609             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
610             echo "__nexus_username__" > /opt/config/nexus_username.txt
611             echo "__nexus_password__" > /opt/config/nexus_password.txt
612             echo "__env_name__" > /opt/config/env_name.txt
613             echo "10.0.11.1" > /opt/config/mr_ip_addr.txt
614             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
615             echo "10.0.0.1" > /opt/config/dns_ip_addr.txt
616             echo "__docker_version__" > /opt/config/docker_version.txt
617             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
618             echo "__cloud_env__" > /opt/config/cloud_env.txt
619
620             # Download and run install script
621             curl -k __nexus_repo__/org.openecomp.demo/boot/__artifacts_version__/asdc_install.sh -o /opt/asdc_install.sh
622             cd /opt
623             chmod +x asdc_install.sh
624             ./asdc_install.sh
625
626
627   # PORTAL instantiation
628   portal_private_port:
629     type: OS::Neutron::Port
630     properties:
631       network: { get_resource: oam_ecomp }
632       fixed_ips: [{"subnet": { get_resource: oam_ecomp_subnet }, "ip_address": 10.0.9.1}]
633
634   portal_volume:
635     type: OS::Cinder::Volume
636     properties:
637       name: vol1-portal
638       size: 50
639       volume_type: SSD
640       image: Ubuntu 14.04 LTS (Trusty Tahr) (PVHVM)
641
642   portal_vm:
643     type: OS::Nova::Server
644     properties:
645       flavor: 15 GB Memory v1
646       name: vm1-portal
647       key_name: { get_resource: vm_key }
648       block_device_mapping:
649         - volume_id: { get_resource: portal_volume }
650           device_name: vda
651       networks:
652         - network: { get_param: public_net_id }
653         - port: { get_resource: portal_private_port }
654       user_data_format: RAW
655       user_data:
656         str_replace:
657           params:
658             __nexus_repo__: { get_param: nexus_repo }
659             __nexus_docker_repo__: { get_param: nexus_docker_repo }
660             __nexus_username__: { get_param: nexus_username }
661             __nexus_password__: { get_param: nexus_password }
662             __artifacts_version__: { get_param: artifacts_version }
663             __docker_version__: { get_param: docker_version }
664             __gerrit_branch__: { get_param: gerrit_branch }
665             __cloud_env__: { get_param: cloud_env }
666           template: |
667             #!/bin/bash
668
669             # Create configuration files
670             mkdir -p /opt/config
671             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
672             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
673             echo "__nexus_username__" > /opt/config/nexus_username.txt
674             echo "__nexus_password__" > /opt/config/nexus_password.txt
675             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
676             echo "10.0.0.1" > /opt/config/dns_ip_addr.txt
677             echo "__docker_version__" > /opt/config/docker_version.txt
678             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
679             echo "__cloud_env__" > /opt/config/cloud_env.txt
680
681             # Download and run install script
682             curl -k __nexus_repo__/org.openecomp.demo/boot/__artifacts_version__/portal_install.sh -o /opt/portal_install.sh
683             cd /opt
684             chmod +x portal_install.sh
685             ./portal_install.sh
686
687
688   # DCAE Controller instantiation
689   dcae_c_private_port:
690     type: OS::Neutron::Port
691     properties:
692       network: { get_resource: oam_ecomp }
693       fixed_ips: [{"subnet": { get_resource: oam_ecomp_subnet }, "ip_address": 10.0.4.1}]
694   dcae_c_vm:
695     type: OS::Nova::Server
696     properties:
697       image: Ubuntu 14.04 LTS (Trusty Tahr) (PVHVM)
698       flavor: 8 GB General Purpose v1
699       name: vm1-dcae-controller
700       key_name: { get_resource: vm_key }
701       networks:
702         - network: { get_param: public_net_id }
703         - port: { get_resource: dcae_c_private_port }
704       user_data_format: RAW
705       user_data:
706         str_replace:
707           params:
708             __nexus_repo__: { get_param: nexus_repo }
709             __nexus_docker_repo__: { get_param: nexus_docker_repo }
710             __nexus_username__: { get_param: nexus_username }
711             __nexus_password__: { get_param: nexus_password }
712             __nexus_url_snapshots__: { get_param: nexus_url_snapshot }
713             __gitlab_branch__: { get_param: gitlab_branch }
714             __dcae_zone__: { get_param: dcae_zone }
715             __dcae_state__: { get_param: dcae_state }
716             __artifacts_version__: { get_param: artifacts_version }
717             __tenant_id__: { get_param: openstack_tenant_id }
718             __openstack_private_network_name__: { get_attr: [oam_ecomp, name] }
719             __openstack_user__: { get_param: openstack_username }
720             __openstack_password__: { get_param: openstack_api_key }
721             __openstack_auth_method__: { get_param: openstack_auth_method }
722             __key_name__: { get_param: key_name }
723             __rand_str__: { get_resource: random-str }
724             __pub_key__: { get_param: pub_key }
725             __nexus_repo_root__: { get_param: nexus_repo_root }
726             __openstack_region__: { get_param: openstack_region }
727             __docker_version__: { get_param: docker_version }
728             __gerrit_branch__: { get_param: gerrit_branch }
729             __cloud_env__: { get_param: cloud_env }
730             __dcae_code_version__: { get_param: dcae_code_version }
731             __public_net_id__: { get_param: public_net_id }
732             __dcae_base_environment__: { get_param: dcae_base_environment }
733             __dcae_ip_addr__: { get_param: dcae_ip_addr }
734             __dcae_coll_ip_addr__: { get_param: dcae_coll_ip_addr }
735             __dcae_db_ip_addr__: { get_param: dcae_db_ip_addr }
736             __dcae_hdp1_ip_addr__: { get_param: dcae_hdp1_ip_addr }
737             __dcae_hdp2_ip_addr__: { get_param: dcae_hdp2_ip_addr }
738             __dcae_hdp3_ip_addr__: { get_param: dcae_hdp3_ip_addr }
739           template: |
740             #!/bin/bash
741
742             # Create configuration files
743             mkdir -p /opt/config
744             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
745             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
746             echo "__nexus_username__" > /opt/config/nexus_username.txt
747             echo "__nexus_password__" > /opt/config/nexus_password.txt
748             echo "__nexus_url_snapshots__" > /opt/config/nexus_url_snapshots.txt
749             echo "__gitlab_branch__" > /opt/config/gitlab_branch.txt
750             echo "__docker_version__" > /opt/config/docker_version.txt
751             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
752             echo "10.0.0.1" > /opt/config/dns_ip_addr.txt
753             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
754             echo "__dcae_zone__" > /opt/config/dcae_zone.txt
755             echo "__dcae_state__" > /opt/config/dcae_state.txt
756             echo "__tenant_id__" > /opt/config/tenant_id.txt
757             echo "__openstack_private_network_name__" > /opt/config/openstack_private_network_name.txt
758             echo "__openstack_user__" > /opt/config/openstack_user.txt
759             echo "__openstack_password__" > /opt/config/openstack_password.txt
760             echo "__openstack_auth_method__" > /opt/config/openstack_auth_method.txt
761             echo "__key_name__" > /opt/config/key_name.txt
762             echo "__rand_str__" > /opt/config/rand_str.txt
763             echo "__pub_key__" > /opt/config/pub_key.txt
764             echo "__nexus_repo_root__" > /opt/config/nexus_repo_root.txt
765             echo "__openstack_region__" > /opt/config/openstack_region.txt
766             echo "https://mycloud.rackspace.com/cloud" > /opt/config/horizon_url.txt
767             echo "https://identity.api.rackspacecloud.com/v2.0" > /opt/config/keystone_url.txt
768             echo "__cloud_env__" > /opt/config/cloud_env.txt
769             echo "__dcae_code_version__" > /opt/config/dcae_code_version.txt
770             echo "__public_net_id__" > /opt/config/public_net_id.txt
771             echo "__dcae_base_environment__" > /opt/config/dcae_base_environment.txt
772             echo "__dcae_ip_addr__" > /opt/config/dcae_ip_addr.txt
773             echo "__dcae_coll_ip_addr__" > /opt/config/dcae_coll_ip_addr.txt
774             echo "__dcae_db_ip_addr__" > /opt/config/dcae_db_ip_addr.txt
775             echo "__dcae_hdp1_ip_addr__" > /opt/config/dcae_hdp1_ip_addr.txt
776             echo "__dcae_hdp2_ip_addr__" > /opt/config/dcae_hdp2_ip_addr.txt
777             echo "__dcae_hdp3_ip_addr__" > /opt/config/dcae_hdp3_ip_addr.txt
778
779             # Download and run install script
780             curl -k __nexus_repo__/org.openecomp.demo/boot/__artifacts_version__/dcae_install.sh -o /opt/dcae_install.sh
781             cd /opt
782             chmod +x dcae_install.sh
783             ./dcae_install.sh
784
785
786   # Policy engine instantiation
787   policy_private_port:
788     type: OS::Neutron::Port
789     properties:
790       network: { get_resource: oam_ecomp }
791       fixed_ips: [{"subnet": { get_resource: oam_ecomp_subnet }, "ip_address": 10.0.6.1}]
792
793   policy_volume:
794     type: OS::Cinder::Volume
795     properties:
796       name: vol1-policy
797       size: 50
798       volume_type: SSD
799       image: Ubuntu 14.04 LTS (Trusty Tahr) (PVHVM)
800
801   policy_vm:
802     type: OS::Nova::Server
803     properties:
804       flavor: 15 GB Compute v1
805       name: vm1-policy
806       key_name: { get_resource: vm_key }
807       block_device_mapping:
808         - volume_id: { get_resource: policy_volume }
809           device_name: vda
810       networks:
811         - network: { get_param: public_net_id }
812         - port: { get_resource: policy_private_port }
813       user_data_format: RAW
814       user_data:
815         str_replace:
816           params:
817             __nexus_repo__: { get_param: nexus_repo }
818             __nexus_docker_repo__: { get_param: nexus_docker_repo }
819             __nexus_username__: { get_param: nexus_username }
820             __nexus_password__: { get_param: nexus_password }
821             __artifacts_version__: { get_param: artifacts_version }
822             __docker_version__: { get_param: docker_version }
823             __gerrit_branch__: { get_param: gerrit_branch }
824             __cloud_env__: { get_param: cloud_env }
825           template: |
826             #!/bin/bash
827
828             # Create configuration files
829             mkdir -p /opt/config
830             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
831             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
832             echo "__nexus_username__" > /opt/config/nexus_username.txt
833             echo "__nexus_password__" > /opt/config/nexus_password.txt
834             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
835             echo "10.0.0.1" > /opt/config/dns_ip_addr.txt
836             echo "__docker_version__" > /opt/config/docker_version.txt
837             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
838             echo "__cloud_env__" > /opt/config/cloud_env.txt
839
840             # Download and run install script
841             curl -k __nexus_repo__/org.openecomp.demo/boot/__artifacts_version__/policy_install.sh -o /opt/policy_install.sh
842             cd /opt
843             chmod +x policy_install.sh
844             ./policy_install.sh
845
846
847   # APP-C instantiation
848   appc_private_port:
849     type: OS::Neutron::Port
850     properties:
851       network: { get_resource: oam_ecomp }
852       fixed_ips: [{"subnet": { get_resource: oam_ecomp_subnet }, "ip_address": 10.0.2.1}]
853
854   appc_vm:
855     type: OS::Nova::Server
856     properties:
857       image: Ubuntu 14.04 LTS (Trusty Tahr) (PVHVM)
858       flavor: 4 GB General Purpose v1
859       name: vm1-appc
860       key_name: { get_resource: vm_key }
861       networks:
862         - network: { get_param: public_net_id }
863         - port: { get_resource: appc_private_port }
864       user_data_format: RAW
865       user_data:
866         str_replace:
867           params:
868             __nexus_repo__: { get_param: nexus_repo }
869             __nexus_docker_repo__: { get_param: nexus_docker_repo }
870             __nexus_username__: { get_param: nexus_username }
871             __nexus_password__: { get_param: nexus_password }
872             __dmaap_topic__: { get_param: dmaap_topic }
873             __artifacts_version__: { get_param: artifacts_version }
874             __docker_version__: { get_param: docker_version }
875             __gerrit_branch__: { get_param: gerrit_branch }
876             __cloud_env__: { get_param: cloud_env }
877           template: |
878             #!/bin/bash
879
880             # Create configuration files
881             mkdir -p /opt/config
882             echo "__nexus_repo__" > /opt/config/nexus_repo.txt
883             echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
884             echo "__nexus_username__" > /opt/config/nexus_username.txt
885             echo "__nexus_password__" > /opt/config/nexus_password.txt
886             echo "__artifacts_version__" > /opt/config/artifacts_version.txt
887             echo "10.0.0.1" > /opt/config/dns_ip_addr.txt
888             echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
889             echo "__docker_version__" > /opt/config/docker_version.txt
890             echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
891             echo "__cloud_env__" > /opt/config/cloud_env.txt
892
893             # Download and run install script
894             curl -k __nexus_repo__/org.openecomp.demo/boot/__artifacts_version__/appc_install.sh -o /opt/appc_install.sh
895             cd /opt
896             chmod +x appc_install.sh
897             ./appc_install.sh