1 heat_template_version: 2013-05-23
3 description: Heat template to deploy vLoadBalancer/vDNS demo app for ONAP
8 label: Image name or ID
9 description: Image to be used for compute instance
13 description: Type of instance (flavor) to be used
16 label: Public network name or ID
17 description: Public network that enables remote connection to VNF
20 label: vLoadBalancer private network name or ID
21 description: Private network that connects vLoadBalancer with vDNSs
24 label: ONAP management network name or ID
25 description: Private network that connects ONAP components and the VNF
26 onap_private_subnet_id:
28 label: ONAP management sub-network name or ID
29 description: Private sub-network that connects ONAP components and the VNF
32 label: vLoadBalancer private network CIDR
33 description: The CIDR of the vLoadBalancer private network
34 onap_private_net_cidr:
36 label: ONAP private network CIDR
37 description: The CIDR of the protected private network
40 label: vLoadBalancer private IP address towards the private network
41 description: Private IP address that is assigned to the vLoadBalancer to communicate with the vDNSs
44 label: vLoadBalancer private IP address towards the ONAP management network
45 description: Private IP address that is assigned to the vLoadBalancer to communicate with ONAP components
48 label: vDNS private IP address towards the private network
49 description: Private IP address that is assigned to the vDNS to communicate with the vLoadBalancer
52 label: vDNS private IP address towards the ONAP management network
53 description: Private IP address that is assigned to the vDNS to communicate with ONAP components
56 label: vLoadBalancer name
57 description: Name of the vLoadBalancer
61 description: Name of the vDNS
65 description: The VNF ID is provided by ONAP
68 label: vFirewall module ID
69 description: The vLoadBalancer Module ID is provided by ONAP
72 label: DCAE collector IP address
73 description: IP address of the DCAE collector
76 label: DCAE collector port
77 description: Port of the DCAE collector
81 description: Public/Private key pair name
85 description: Public key to be installed on the compute instance
89 description: URL of the repository that hosts the demo packages
93 description: URL of the repository that hosts the demo packages
94 install_script_version:
96 label: Installation script version number
97 description: Version number of the scripts that install the vFW demo app
98 demo_artifacts_version:
100 label: Artifacts version used in demo vnfs
101 description: Artifacts (jar, tar.gz) version used in demo vnfs
104 label: Cloud environment
105 description: Cloud environment (e.g., openstack, rackspace)
110 type: OS::Heat::RandomString
115 type: OS::Nova::KeyPair
121 base: { get_param: key_name }
122 rand: { get_resource: random-str }
123 public_key: { get_param: pub_key }
124 save_private_key: false
127 type: OS::Neutron::Net
129 name: { get_param: vlb_private_net_id }
132 type: OS::Neutron::Subnet
134 name: { get_param: vlb_private_net_id }
135 network_id: { get_resource: vlb_private_network }
136 cidr: { get_param: vlb_private_net_cidr }
138 # Virtual Load Balancer Instantiation
140 type: OS::Neutron::Port
142 network: { get_resource: vlb_private_network }
143 fixed_ips: [{"subnet": { get_resource: vlb_private_subnet }, "ip_address": { get_param: vlb_private_ip_0 }}]
146 type: OS::Neutron::Port
148 network: { get_param: onap_private_net_id }
149 fixed_ips: [{"subnet": { get_param: onap_private_subnet_id }, "ip_address": { get_param: vlb_private_ip_1 }}]
152 type: OS::Nova::Server
154 image: { get_param: vlb_image_name }
155 flavor: { get_param: vlb_flavor_name }
156 name: { get_param: vlb_name_0 }
157 key_name: { get_resource: my_keypair }
159 - network: { get_param: public_net_id }
160 - port: { get_resource: vlb_private_0_port }
161 - port: { get_resource: vlb_private_1_port }
162 metadata: {vnf_id: { get_param: vnf_id }, vf_module_id: { get_param: vf_module_id }}
163 user_data_format: RAW
167 __dcae_collector_ip__: { get_param: dcae_collector_ip }
168 __dcae_collector_port__: { get_param: dcae_collector_port }
169 __local_private_ipaddr__: { get_param: vlb_private_ip_0 }
170 __local_public_ipaddr__: { get_attr: [vlb_0, first_address] }
171 __repo_url_blob__ : { get_param: repo_url_blob }
172 __repo_url_artifacts__ : { get_param: repo_url_artifacts }
173 __demo_artifacts_version__ : { get_param: demo_artifacts_version }
174 __install_script_version__ : { get_param: install_script_version }
175 __cloud_env__ : { get_param: cloud_env }
179 # Create configuration files
181 echo "__dcae_collector_ip__" > /opt/config/dcae_collector_ip.txt
182 echo "__dcae_collector_port__" > /opt/config/dcae_collector_port.txt
183 echo "__local_private_ipaddr__" > /opt/config/local_private_ipaddr.txt
184 echo "__local_public_ipaddr__" > /opt/config/local_public_ipaddr.txt
185 echo "__repo_url_blob__" > /opt/config/repo_url_blob.txt
186 echo "__repo_url_artifacts__" > /opt/config/repo_url_artifacts.txt
187 echo "__demo_artifacts_version__" > /opt/config/demo_artifacts_version.txt
188 echo "__install_script_version__" > /opt/config/install_script_version.txt
189 echo "__cloud_env__" > /opt/config/cloud_env.txt
191 # Download and run install script
192 curl -k __repo_url_blob__/org.openecomp.demo/vnfs/vlb/__install_script_version__/v_lb_install.sh -o /opt/v_lb_install.sh
194 chmod +x v_lb_install.sh
198 # Virtual DNS Instantiation
200 type: OS::Neutron::Port
202 network: { get_resource: vlb_private_network }
203 fixed_ips: [{"subnet": { get_resource: vlb_private_subnet }, "ip_address": { get_param: vdns_private_ip_0 }}]
206 type: OS::Neutron::Port
208 network: { get_param: onap_private_net_id }
209 fixed_ips: [{"subnet": { get_param: onap_private_subnet_id }, "ip_address": { get_param: vdns_private_ip_1 }}]
212 type: OS::Nova::Server
214 image: { get_param: vlb_image_name }
215 flavor: { get_param: vlb_flavor_name }
216 name: { get_param: vdns_name_0 }
217 key_name: { get_resource: my_keypair }
219 - network: { get_param: public_net_id }
220 - port: { get_resource: vdns_private_0_port }
221 - port: { get_resource: vdns_private_1_port }
222 metadata: {vnf_id: { get_param: vnf_id }, vf_module_id: { get_param: vf_module_id }}
223 user_data_format: RAW
227 __lb_oam_int__ : { get_param: vlb_private_ip_1 }
228 __lb_private_ipaddr__: { get_param: vlb_private_ip_0 }
229 __local_private_ipaddr__: { get_param: vdns_private_ip_0 }
230 __repo_url_blob__ : { get_param: repo_url_blob }
231 __repo_url_artifacts__ : { get_param: repo_url_artifacts }
232 __demo_artifacts_version__ : { get_param: demo_artifacts_version }
233 __install_script_version__ : { get_param: install_script_version }
234 __cloud_env__ : { get_param: cloud_env }
238 # Create configuration files
240 echo "__lb_oam_int__" > /opt/config/lb_oam_int.txt
241 echo "__lb_private_ipaddr__" > /opt/config/lb_private_ipaddr.txt
242 echo "__local_private_ipaddr__" > /opt/config/local_private_ipaddr.txt
243 echo "__repo_url_blob__" > /opt/config/repo_url_blob.txt
244 echo "__repo_url_artifacts__" > /opt/config/repo_url_artifacts.txt
245 echo "__demo_artifacts_version__" > /opt/config/demo_artifacts_version.txt
246 echo "__install_script_version__" > /opt/config/install_script_version.txt
247 echo "__cloud_env__" > /opt/config/cloud_env.txt
249 # Download and run install script
250 curl -k __repo_url_blob__/org.openecomp.demo/vnfs/vlb/__install_script_version__/v_dns_install.sh -o /opt/v_dns_install.sh
252 chmod +x v_dns_install.sh