1 ##########################################################################
3 #==================LICENSE_START==========================================
6 # Copyright 2017 AT&T Intellectual Property. All rights reserved.
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
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.
19 #==================LICENSE_END============================================
21 # ECOMP is a trademark and service mark of AT&T Intellectual Property.
23 ##########################################################################
25 heat_template_version: 2013-05-23
27 description: Heat template to deploy vCPE vBRG Emulator (vBRGEMU ) for ONAP
29 #######################################################################
33 # 0_port should get IP address from DHCP discover through vBNG #
34 # DCAE is not monitoring the BRGEMULATOR #
35 #######################################################################
40 label: Image name or ID
41 description: Image to be used for compute instance
45 description: Type of instance (flavor) to be used
48 label: Public network name or ID
49 description: Public network that enables remote connection to VNF
50 vbrgemu_bng_private_net_id:
52 label: vBNG private network name or ID
53 description: Private network that connects vBRGEMU to vBNG
54 vbrgemu_private_net_id:
56 label: vBRGEMU Home private network name or ID
57 description: Private network that connects vBRGEMU to local devices
58 vbrgemu_private_net_cidr:
60 label: vBRGEMU Home private network CIDR
61 description: The CIDR of the input side of vBRGEMU Home private network
64 label: vGW IN private IP address
65 description: Private IP address that is assigned to the vBRGEMU (SHOULD NOT BE NEEDED)
69 description: Name of the vGW
73 description: The VNF ID is provided by ONAP
77 description: The vCPE Module ID is provided by ONAP
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)
116 type: OS::Heat::RandomString
121 type: OS::Nova::KeyPair
127 base: { get_param: key_name }
128 rand: { get_resource: random-str }
129 public_key: { get_param: pub_key }
130 save_private_key: false
132 vbrgemu_private_network:
133 type: OS::Neutron::Net
135 name: { get_param: vbrgemu_private_net_id }
137 vbrgemu_private_subnet:
138 type: OS::Neutron::Subnet
140 name: { get_param: vbrgemu_private_net_id }
141 network_id: { get_resource: vbrgemu_private_network }
142 cidr: { get_param: vbrgemu_private_net_cidr }
144 # Virtual BRG Emulator Instantiation
145 # 0_port should get IP address from DHCP discover through vBNG
146 vbrgemu_private_0_port:
147 type: OS::Neutron::Port
149 network: { get_param: vbrgemu_bng_private_net_id}
151 vbrgemu_private_0_port:
152 type: OS::Neutron::Port
154 network: { get_param: vbrgemu_private_net_id}
155 fixed_ips: [{"subnet": { get_resource: vbrgemu_private_subnet}, "ip_address": { get_param: vbrgemu_private_ip_1 }}]
158 type: OS::Nova::Server
160 image: { get_param: vcpe_image_name }
161 flavor: { get_param: vcpe_flavor_name }
162 name: { get_param: vbrgemu_name_0 }
163 key_name: { get_resource: my_keypair }
165 - network: { get_param: public_net_id }
166 - port: { get_resource: vbrgemu_private_0_port }
167 - port: { get_resource: vbrgemu_private_1_port }
168 metadata: {vnf_id: { get_param: vnf_id }, vf_module_id: { get_param: vf_module_id }}
169 user_data_format: RAW
173 __repo_url_blob__ : { get_param: repo_url_blob }
174 __repo_url_artifacts__ : { get_param: repo_url_artifacts }
175 __demo_artifacts_version__ : { get_param: demo_artifacts_version }
176 __install_script_version__ : { get_param: install_script_version }
177 __cloud_env__ : { get_param: cloud_env }
181 # Create configuration files
183 echo "__repo_url_blob__" > /opt/config/repo_url_blob.txt
184 echo "__repo_url_artifacts__" > /opt/config/repo_url_artifacts.txt
185 echo "__demo_artifacts_version__" > /opt/config/demo_artifacts_version.txt
186 echo "__install_script_version__" > /opt/config/install_script_version.txt
187 echo "__cloud_env__" > /opt/config/cloud_env.txt
189 # Download and run install script
190 curl -k __repo_url_blob__/org.openecomp.demo/vnfs/vbrgemu/__install_script_version__/v_brgemu_install.sh -o /opt/v_brgemu_install.sh
192 chmod +x v_brgemu_install.sh
193 ./v_brgemu_install.sh