7a06f07481b9e0518281f4d2cac2a92aeab5b2c5
[sdc.git] /
1 heat_template_version: 2013-05-23
2 description: >
3   SC1, SC2, PL3 and PL4. This is the main template, to be used to create an initial stack, with 1 mated pair
4 parameters:
5   ntp_servers:
6     type: comma_delimited_list
7     description: comma delimited list of NTP servers required by System Controller VMs. Exactly 2 IPv4 values are required
8   sbg_pl_flavor_name:
9     type: string
10     description: Flavor to use for PL VM. Minimum 8 non-HT vCPU and 64GB RAM required
11   sbg_sc_flavor_name:
12     type: string
13     description: Flavor to use for SC VM. Minimum 4 non-HT vCPU and 16GB RAM required
14   vnf_id:
15     type: string
16     description: Unique ID for this VF instance
17   vf_module_id:
18     type: string
19     description: Unique ID for this VNF Module instance
20   sbg_sc_names:
21     type: comma_delimited_list
22     description: comma delimited list of VM names assigned to System Controller VMs
23   sbg_pl_names:
24     type: comma_delimited_list
25     description: comma delimited list of VM names assigned to Payload VMs
26   sbg_internal_cidr:
27     type: string
28     description: Network address (CIDR notation) for SBG intra-VM communication, IPv4. Don't deviate from default!
29     constraints:
30       - allowed_pattern: '(?:[0-9]{1,3}\.){3}[0-9]{1,3}\/[1-2][0-9]'
31         description: A valid IPv4 CIDR notation must be provided, e.g. 192.168.0.0/24
32   sbg_internal_allocation_pool_start_ip:
33     type: string
34     description: The start IP of the Internal network's allocation pool. Don't deviate from default!
35     constraints:
36       - allowed_pattern: '(?:[0-9]{1,3}\.){3}[0-9]{1,3}'
37         description: A valid IPv4 address must be provided, e.g 169.254.100.253
38   sbg_internal_allocation_pool_end_ip:
39     type: string
40     description: The end IP of the Internal network's allocation pool. Don't deviate from default!
41     constraints:
42       - allowed_pattern: '(?:[0-9]{1,3}\.){3}[0-9]{1,3}'
43         description: A valid IPv4 address must be provided, e.g 169.254.100.254
44   internal_net_id:
45     type: string
46     description: the UUID of the operator-created Internal network
47     constraints:
48       - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
49         description: A valid OpenStack UUID must be provided
50   sbg_internal_ips:
51     type: comma_delimited_list
52     description: comma delimited list of IPv4 addresses of SBG VMs on the Internal network. Don't deviate from the default values.
53   sbg_internal_mac_addresses:
54     type: comma_delimited_list
55     description: comma delimited list of MAC addresses for the VMs on the Internal network
56   sbg_management_cidr:
57     type: string
58     description: Network address (CIDR notation) for SBG Management Network, IPv4
59     constraints:
60       - allowed_pattern: '(?:[0-9]{1,3}\.){3}[0-9]{1,3}\/[1-2][0-9]'
61         description: A valid IPv4 CIDR notation must be provided, e.g. 192.168.0.0/24
62   sbg_management_gateway_ip_0:
63     type: string
64     description: IPv4 IP address of the default gateway on Management network
65     constraints:
66       - allowed_pattern: '(?:[0-9]{1,3}\.){3}[0-9]{1,3}'
67         description: A valid IPv4 address must be provided, e.g 192.168.0.1
68   management_net_id:
69     type: string
70     description: the UUID of the operator-created Management network
71     constraints:
72       - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
73         description: A valid OpenStack UUID must be provided
74   management_subnet_id:
75     type: string
76     description: the UUID of the operator-created Management subnet, IPv4
77     constraints:
78       - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
79         description: A valid OpenStack UUID must be provided
80   sbg_management_mac_addresses:
81     type: comma_delimited_list
82     description: comma delimited list of MAC addresses for the VMs on the Management network
83   sbg_management_ips:
84     type: comma_delimited_list
85     description: comma delimited list of IPv4 addresses of SBG VMs on the Management network.
86   trunk_net_id:
87     type: string
88     description: the UUID of the operator-created Traffic network
89     constraints:
90        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
91          description: A valid OpenStack UUID must be provided
92   core_net_id:
93     type: string
94     description: the UUID of the operator-created Core network
95     constraints:
96        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
97          description: A valid OpenStack UUID must be provided
98   sbg_core_vlan_tag:
99     type: number
100     description: The internal VLAN TAG for Core network
101     constraints:
102        - range: { min: 1, max: 4096 }
103          description: A valid 802.1Q VLAN TAG must be provided
104   core_subnet_id:
105     type: string
106     description: the UUID of the operator-created Core subnet, IPv4
107     constraints:
108        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
109          description: A valid OpenStack UUID must be provided
110   core_v6_subnet_id:
111     type: string
112     description: the UUID of the operator-created Core subnet, IPv6
113     constraints:
114        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
115          description: A valid OpenStack UUID must be provided
116   sbg_core_ips:
117     type: comma_delimited_list
118     description: comma delimited list of IPv4 IPs to be used on Core network
119   sbg_core_v6_IPs:
120     type: comma_delimited_list
121     description: comma delimited list of IPv6 IPs to be used on Core network
122   charging_net_id:
123     type: string
124     description: the UUID of the operator-created Charging network
125     constraints:
126        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
127          description: A valid OpenStack UUID must be provided
128   sbg_charging_vlan_tag:
129     type: number
130     description: The internal VLAN TAG for Charging network
131     constraints:
132        - range: { min: 1, max: 4096 }
133          description: A valid 802.1Q VLAN TAG must be provided
134   sbg_charging_ips:
135     type: comma_delimited_list
136     description: comma delimited list of IPv4 IPs to be used on Charging network
137   access_net_id:
138     type: string
139     description: the UUID of the operator-created Access network
140     constraints:
141        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
142          description: A valid OpenStack UUID must be provided
143   sbg_access_vlan_tag:
144     type: number
145     description: The internal VLAN TAG for Access network
146     constraints:
147        - range: { min: 1, max: 4096 }
148          description: A valid 802.1Q VLAN TAG must be provided
149   access_subnet_id:
150     type: string
151     description: the UUID of the operator-created Access subnet, IPv4
152     constraints:
153        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
154          description: A valid OpenStack UUID must be provided
155   sbg_access_ips:
156     type: comma_delimited_list
157     description: comma delimited list of IPv4 IPs to be used on Access network
158   sbg_AVPN_count:
159     type: number
160     description: The number of AVPN networks
161     constraints:
162        - range: { min: 1, max: 999 }
163   avpn_net_id:
164     type: comma_delimited_list
165     description: comma delimited list of the UUIDs of the operator-created AVPN networks
166   sbg_AVPN_vlan_tag_list:
167     type: comma_delimited_list
168     description: comma delimited list of internal VLAN TAG(s) used by AVPN networks
169   avpn_subnet_id:
170     type: comma_delimited_list
171     description: comma delimited list of the UUIDs of the operator created IPv4 AVPN subnets
172   sbg_avpn_ips:
173     type: comma_delimited_list
174     description: >
175        comma delimited list of IPv4 IPs to be used on AVPN networks. n*2 IP address expected where n is the number of PL VM pairs. The first two addresses are assigned to the first PL VM pair, second two IPs to the second PL VM pair, and so on. Note: this is true regardless of the number of AVPN networks and sbg_AVPN_count.
176   sgi_net_id:
177     type: string
178     description: the UUID of the operator-created SGI network
179     constraints:
180        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
181          description: A valid OpenStack UUID must be provided
182   sbg_SGI_vlan_tag:
183     type: number
184     description: The internal VLAN TAG for SGI network
185     constraints:
186        - range: { min: 1, max: 4096 }
187          description: A valid 802.1Q VLAN TAG must be provided
188   sgi_subnet_id:
189     type: string
190     description: the UUID of the operator-created SGI subnet, IPv4
191     constraints:
192        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
193          description: A valid OpenStack UUID must be provided
194   sbg_sgi_ips:
195     type: comma_delimited_list
196     description: comma delimited list of IPv4 IPs to be used on SGI network
197   UCOM_net_id:
198     type: string
199     description: the UUID of the operator-created UC One Mobile network
200     constraints:
201        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
202          description: A valid OpenStack UUID must be provided
203   sbg_UCOM_vlan_tag:
204     type: number
205     description: The internal VLAN TAG for UC One Mobile network
206     constraints:
207        - range: { min: 1, max: 4096 }
208          description: A valid 802.1Q VLAN TAG must be provided
209   UCOM_subnet_id:
210     type: string
211     description: the UUID of the operator-created UC One Mobile subnet, IPv4
212     constraints:
213        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
214          description: A valid OpenStack UUID must be provided
215   sbg_UCOM_ips:
216     type: comma_delimited_list
217     description: comma delimited list of IPv4 IPs to be used on UC One Mobile network
218   dummy_net_id:
219     type: string
220     description: the UUID of the operator-created Dummy network
221     constraints:
222        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
223          description: A valid OpenStack UUID must be provided
224   dummy_subnet_id:
225     type: string
226     description: the UUID of the operator-created dummy subnet, IPv4
227     constraints:
228        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
229          description: A valid OpenStack UUID must be provided
230   sbg_dummy_ips:
231     type: comma_delimited_list
232     description: comma delimited list of IPv4 IPs to be used on Dummy network
233   sbg_pl_image_name:
234     description: the name of the Glance PXE boot image for PL VMs
235     type: string
236   sbg_management_floating_ip:
237     type: string
238     description: Moveable Management IP (VIP), IPv4
239     constraints:
240       - allowed_pattern: '(?:[0-9]{1,3}\.){3}[0-9]{1,3}'
241         description: A valid IPv4 address must be provided, e.g 192.168.0.1
242   availability_zone_0:
243     type: string
244     description: First availability zone ID or Name.
245   availability_zone_1:
246     type: string
247     description: Second availability zone ID or Name.
248   sbg_nfs_floating_ip:
249     type: string
250     description: Moveable IP (VIP) for NFS server on the Internal network, IPv4. Don't deviate from default!
251     constraints:
252       - allowed_pattern: '(?:[0-9]{1,3}\.){3}[0-9]{1,3}'
253         description: A valid IPv4 address must be provided, e.g 192.168.0.1
254   sbg_comte_floating_ip:
255     type: string
256     description: Moveable IP (VIP) for COM on the Internal network, IPv4. Don't deviate from default!
257     constraints:
258       - allowed_pattern: '(?:[0-9]{1,3}\.){3}[0-9]{1,3}'
259         description: A valid IPv4 address must be provided, e.g 192.168.0.1
260   sbg_boot_floating_ip:
261     type: string
262     description: Moveable IP (VIP) for TFTP server on the Internal network, IPv4. Don't deviate from default!
263     constraints:
264       - allowed_pattern: '(?:[0-9]{1,3}\.){3}[0-9]{1,3}'
265         description: A valid IPv4 address must be provided, e.g 192.168.0.1
266   sbg_timezone:
267     description: Timezone.
268     type: string
269
270   sbg_sc_volume_id_0:
271     type: string
272     description: the UUID of the pre-created Cinder volume attached to SC-1 as root volume
273     constraints:
274        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
275          description: A valid OpenStack UUID must be provided
276   sbg_sc_volume_id_1:
277     type: string
278     description: the UUID of the pre-created Cinder volume attached to SC-1 as tools volume
279     constraints:
280        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
281          description: A valid OpenStack UUID must be provided
282   sbg_sc_volume_id_2:
283     type: string
284     description: the UUID of the pre-created Cinder volume attached to SC-2 as root volume
285     constraints:
286        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
287          description: A valid OpenStack UUID must be provided
288   sbg_sc_volume_id_3:
289     type: string
290     description: the UUID of the pre-created Cinder volume attached to SC-2 as tools volume
291     constraints:
292        - allowed_pattern: '[a-f0-9]{8}\-(?:[a-f0-9]{4}\-){3}[a-f0-9]{12}'
293          description: A valid OpenStack UUID must be provided
294
295 resources:
296   sbg_sc_internal_0_port_0:
297     type: OS::Neutron::Port
298     properties:
299       replacement_policy: AUTO
300       network_id: { get_param: internal_net_id }
301       fixed_ips:
302       - ip_address: { get_param: [sbg_internal_ips ,0] }
303       allowed_address_pairs:
304       - ip_address: { get_param: sbg_nfs_floating_ip }
305       - ip_address: { get_param: sbg_comte_floating_ip }
306       - ip_address: { get_param: sbg_boot_floating_ip }
307       mac_address: { get_param: [sbg_internal_mac_addresses ,0] }
308
309   sbg_sc_management_1_port_0:
310     type: OS::Neutron::Port
311     properties:
312       replacement_policy: AUTO
313       network_id: { get_param: management_net_id }
314       fixed_ips:
315       - ip_address: { get_param: [sbg_management_ips ,0] }
316       allowed_address_pairs:
317       - ip_address: { get_param: sbg_management_floating_ip }
318       mac_address: { get_param: [sbg_management_mac_addresses ,0] }
319
320   sbg_pl_internal_0_port_0:
321       type: OS::Neutron::Port
322       properties:
323         replacement_policy: AUTO
324         network_id: { get_param: internal_net_id }
325         fixed_ips:
326           - ip_address: { get_param: [sbg_internal_ips ,2] }
327         mac_address: { get_param: [sbg_internal_mac_addresses ,2] }
328
329   sbg_pl_trunk_1_port_0:
330     type: OS::Neutron::Port
331     properties:
332       replacement_policy: AUTO
333       network_id: { get_param: trunk_net_id }
334       value_specs:
335         trunkport:type: 'trunk'
336
337   sbg_pl_trunk_subport_avpn_group_0:
338     depends_on: [ sbg_pl_internal_0_port_0, sbg_pl_trunk_1_port_0  ]
339     type: OS::Heat::ResourceGroup
340     properties:
341       count: {get_param: sbg_AVPN_count}
342       resource_def:
343         type: DPA3_New_VNF_TSBGv_nested_AVPN_subport.yaml
344         properties:
345           nested_trunk_port_id: {get_resource: sbg_pl_trunk_1_port_0}
346           nested_sbg_AVPN_vlan_tag_list: {get_param: sbg_AVPN_vlan_tag_list}
347           nested_avpn_net_id: {get_param: avpn_net_id}
348           nested_avpn_subnet_id: {get_param: avpn_subnet_id}
349           nested_sbg_avpn_ip_0: {get_param: [sbg_avpn_ips, 0]}
350           nested_sbg_AVPN_counter: '%index%'
351
352   sbg_sc_0:
353     type: OS::Nova::Server
354     depends_on: [ sbg_sc_internal_0_port_0, sbg_sc_management_1_port_0 ]
355     properties:
356       name: { get_param: [sbg_sc_names, 0]}
357       metadata:
358         vnf_id: { get_param: vnf_id }
359         vf_module_id: { get_param: vf_module_id }
360       availability_zone: { get_param: availability_zone_0 }
361       block_device_mapping:
362       - device_name: "vda"
363         volume_id : { get_param : sbg_sc_volume_id_0 }
364         delete_on_termination : "false"
365       - device_name: "vdb"
366         volume_id : { get_param : sbg_sc_volume_id_1 }
367         delete_on_termination : "false"
368       flavor: { get_param: sbg_sc_flavor_name }
369       networks:
370       - port: { get_resource: sbg_sc_internal_0_port_0 }
371       - port: { get_resource: sbg_sc_management_1_port_0 }
372       config_drive: "true"
373       user_data_format: RAW