1 heat_template_version: 2013-05-23
3 description: Heat template that deploys vFirewall 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
18 unprotected_private_net_id:
20 label: Unprotected private network name or ID
21 description: Private network that connects vPacketGenerator with vFirewall
22 protected_private_net_id:
24 label: Protected private network name or ID
25 description: Private network that connects vFirewall with vSink
28 label: ONAP management network name or ID
29 description: Private network that connects ONAP components and the VNF
30 onap_private_subnet_id:
32 label: ONAP management sub-network name or ID
33 description: Private sub-network that connects ONAP components and the VNF
34 unprotected_private_net_cidr:
36 label: Unprotected private network CIDR
37 description: The CIDR of the unprotected private network
38 protected_private_net_cidr:
40 label: Protected private network CIDR
41 description: The CIDR of the protected private network
42 onap_private_net_cidr:
44 label: ONAP private network CIDR
45 description: The CIDR of the protected private network
48 label: vFirewall private IP address towards the unprotected network
49 description: Private IP address that is assigned to the vFirewall to communicate with the vPacketGenerator
52 label: vFirewall private IP address towards the protected network
53 description: Private IP address that is assigned to the vFirewall to communicate with the vSink
56 label: vFirewall private IP address towards the ONAP management network
57 description: Private IP address that is assigned to the vFirewall to communicate with ONAP components
60 label: vPacketGenerator private IP address towards the unprotected network
61 description: Private IP address that is assigned to the vPacketGenerator to communicate with the vFirewall
64 label: vPacketGenerator private IP address towards the ONAP management network
65 description: Private IP address that is assigned to the vPacketGenerator to communicate with ONAP components
68 label: vSink private IP address towards the protected network
69 description: Private IP address that is assigned to the vSink to communicate with the vFirewall
72 label: vSink private IP address towards the ONAP management network
73 description: Private IP address that is assigned to the vSink to communicate with ONAP components
77 description: Name of the vFirewall
80 label: vPacketGenerator name
81 description: Name of the vPacketGenerator
85 description: Name of the vSink
89 description: The VNF ID is provided by ECOMP
92 label: vFirewall module ID
93 description: The vFirewall Module ID is provided by ECOMP
96 label: DCAE collector IP address
97 description: IP address of the DCAE collector
100 label: DCAE collector port
101 description: Port of the DCAE collector
105 description: Public/Private key pair name
109 description: Public key to be installed on the compute instance
112 label: Repository URL
113 description: URL of the repository that hosts the demo packages
116 label: Repository URL
117 description: URL of the repository that hosts the demo packages
118 install_script_version:
120 label: Installation script version number
121 description: Version number of the scripts that install the vFW demo app
122 demo_artifacts_version:
124 label: Artifacts version used in demo vnfs
125 description: Artifacts (jar, tar.gz) version used in demo vnfs
128 label: Cloud environment
129 description: Cloud environment (e.g., openstack, rackspace)
133 type: OS::Heat::RandomString
138 type: OS::Nova::KeyPair
144 base: { get_param: key_name }
145 rand: { get_resource: random-str }
146 public_key: { get_param: pub_key }
147 save_private_key: false
149 unprotected_private_network:
150 type: OS::Neutron::Net
152 name: { get_param: unprotected_private_net_id }
154 protected_private_network:
155 type: OS::Neutron::Net
157 name: { get_param: protected_private_net_id }
159 unprotected_private_subnet:
160 type: OS::Neutron::Subnet
162 network_id: { get_resource: unprotected_private_network }
163 cidr: { get_param: unprotected_private_net_cidr }
165 protected_private_subnet:
166 type: OS::Neutron::Subnet
168 network_id: { get_resource: protected_private_network }
169 cidr: { get_param: protected_private_net_cidr }
171 # Virtual Firewall instantiation
173 type: OS::Neutron::Port
175 network: { get_resource: unprotected_private_network }
176 fixed_ips: [{"subnet": { get_resource: unprotected_private_subnet }, "ip_address": { get_param: vfw_private_ip_0 }}]
179 type: OS::Neutron::Port
181 network: { get_resource: protected_private_network }
182 fixed_ips: [{"subnet": { get_resource: protected_private_subnet }, "ip_address": { get_param: vfw_private_ip_1 }}]
185 type: OS::Neutron::Port
187 network: { get_param: onap_private_net_id }
188 fixed_ips: [{"subnet": { get_param: onap_private_subnet_id }, "ip_address": { get_param: vfw_private_ip_2 }}]
191 type: OS::Nova::Server
193 image: { get_param: vfw_image_name }
194 flavor: { get_param: vfw_flavor_name }
195 name: { get_param: vfw_name_0 }
196 key_name: { get_resource: my_keypair }
198 - network: { get_param: public_net_id }
199 - port: { get_resource: vfw_private_0_port }
200 - port: { get_resource: vfw_private_1_port }
201 - port: { get_resource: vfw_private_2_port }
202 metadata: {vnf_id: { get_param: vnf_id }, vf_module_id: { get_param: vf_module_id }}
203 user_data_format: RAW
207 __dcae_collector_ip__ : { get_param: dcae_collector_ip }
208 __dcae_collector_port__ : { get_param: dcae_collector_port }
209 __repo_url_blob__ : { get_param: repo_url_blob }
210 __repo_url_artifacts__ : { get_param: repo_url_artifacts }
211 __demo_artifacts_version__ : { get_param: demo_artifacts_version }
212 __install_script_version__ : { get_param: install_script_version }
213 __cloud_env__ : { get_param: cloud_env }
217 # Create configuration files
219 echo "__dcae_collector_ip__" > /opt/config/dcae_collector_ip.txt
220 echo "__dcae_collector_port__" > /opt/config/dcae_collector_port.txt
221 echo "__repo_url_blob__" > /opt/config/repo_url_blob.txt
222 echo "__repo_url_artifacts__" > /opt/config/repo_url_artifacts.txt
223 echo "__demo_artifacts_version__" > /opt/config/demo_artifacts_version.txt
224 echo "__install_script_version__" > /opt/config/install_script_version.txt
225 echo "__cloud_env__" > /opt/config/cloud_env.txt
227 # Download and run install script
228 curl -k __repo_url_blob__/org.openecomp.demo/vnfs/vfw/__install_script_version__/v_firewall_install.sh -o /opt/v_firewall_install.sh
230 chmod +x v_firewall_install.sh
231 ./v_firewall_install.sh
234 # Virtual Packet Generator instantiation
236 type: OS::Neutron::Port
238 network: { get_resource: unprotected_private_network }
239 fixed_ips: [{"subnet": { get_resource: unprotected_private_subnet }, "ip_address": { get_param: vpg_private_ip_0 }}]
242 type: OS::Neutron::Port
244 network: { get_param: onap_private_net_id }
245 fixed_ips: [{"subnet": { get_param: onap_private_subnet_id }, "ip_address": { get_param: vpg_private_ip_1 }}]
248 type: OS::Nova::Server
250 image: { get_param: vfw_image_name }
251 flavor: { get_param: vfw_flavor_name }
252 name: { get_param: vpg_name_0 }
253 key_name: { get_resource: my_keypair }
255 - network: { get_param: public_net_id }
256 - port: { get_resource: vpg_private_0_port }
257 - port: { get_resource: vpg_private_1_port }
258 metadata: {vnf_id: { get_param: vnf_id }, vf_module_id: { get_param: vf_module_id }}
259 user_data_format: RAW
263 __fw_ipaddr__: { get_param: vfw_private_ip_0 }
264 __protected_net_cidr__: { get_param: protected_private_net_cidr }
265 __sink_ipaddr__: { get_param: vsn_private_ip_0 }
266 __repo_url_blob__ : { get_param: repo_url_blob }
267 __repo_url_artifacts__ : { get_param: repo_url_artifacts }
268 __demo_artifacts_version__ : { get_param: demo_artifacts_version }
269 __install_script_version__ : { get_param: install_script_version }
270 __cloud_env__ : { get_param: cloud_env }
274 # Create configuration files
276 echo "__fw_ipaddr__" > /opt/config/fw_ipaddr.txt
277 echo "__protected_net_cidr__" > /opt/config/protected_net_cidr.txt
278 echo "__sink_ipaddr__" > /opt/config/sink_ipaddr.txt
279 echo "__repo_url_blob__" > /opt/config/repo_url_blob.txt
280 echo "__repo_url_artifacts__" > /opt/config/repo_url_artifacts.txt
281 echo "__demo_artifacts_version__" > /opt/config/demo_artifacts_version.txt
282 echo "__install_script_version__" > /opt/config/install_script_version.txt
283 echo "__cloud_env__" > /opt/config/cloud_env.txt
285 # Download and run install script
286 curl -k __repo_url_blob__/org.openecomp.demo/vnfs/vfw/__install_script_version__/v_packetgen_install.sh -o /opt/v_packetgen_install.sh
288 chmod +x v_packetgen_install.sh
289 ./v_packetgen_install.sh
292 # Virtual Sink instantiation
294 type: OS::Neutron::Port
296 network: { get_resource: protected_private_network }
297 fixed_ips: [{"subnet": { get_resource: protected_private_subnet }, "ip_address": { get_param: vsn_private_ip_0 }}]
300 type: OS::Neutron::Port
302 network: { get_param: onap_private_net_id }
303 fixed_ips: [{"subnet": { get_param: onap_private_subnet_id }, "ip_address": { get_param: vsn_private_ip_1 }}]
306 type: OS::Nova::Server
308 image: { get_param: vfw_image_name }
309 flavor: { get_param: vfw_flavor_name }
310 name: { get_param: vsn_name_0 }
311 key_name: { get_resource: my_keypair }
313 - network: { get_param: public_net_id }
314 - port: { get_resource: vsn_private_0_port }
315 - port: { get_resource: vsn_private_1_port }
316 metadata: {vnf_id: { get_param: vnf_id }, vf_module_id: { get_param: vf_module_id }}
317 user_data_format: RAW
321 __protected_net_gw__: { get_param: vfw_private_ip_1 }
322 __unprotected_net__: { get_param: unprotected_private_net_cidr }
323 __repo_url_blob__ : { get_param: repo_url_blob }
324 __install_script_version__ : { get_param: install_script_version }
325 __cloud_env__ : { get_param: cloud_env }
329 # Create configuration files
331 echo "__protected_net_gw__" > /opt/config/protected_net_gw.txt
332 echo "__unprotected_net__" > /opt/config/unprotected_net.txt
333 echo "__repo_url_blob__" > /opt/config/repo_url_blob.txt
334 echo "__install_script_version__" > /opt/config/install_script_version.txt
335 echo "__cloud_env__" > /opt/config/cloud_env.txt
337 # Download and run install script
338 curl -k __repo_url_blob__/org.openecomp.demo/vnfs/vfw/__install_script_version__/v_sink_install.sh -o /opt/v_sink_install.sh
340 chmod +x v_sink_install.sh