blob: 9b9495a33bc1ba78e00bf3e8bddc40d9eeeaeb67 [file] [log] [blame]
Gary Wu11c98742018-05-02 16:19:04 -07001#
2# Generated by scripts/gen-onap-oom-yaml.sh; MANUAL CHANGES WILL BE LOST
3#
Gary Wuccd529b2018-01-16 18:31:01 -08004heat_template_version: 2015-10-15
5description: ONAP on Kubernetes using OOM
6
7parameters:
Gary Wuccd529b2018-01-16 18:31:01 -08008 docker_proxy:
9 type: string
10
11 apt_proxy:
12 type: string
13
Gary Wuc98156d2018-01-18 12:03:26 -080014 public_net_id:
15 type: string
16 description: The ID of the Public network for floating IP address allocation
17
Gary Wuc98156d2018-01-18 12:03:26 -080018 oam_network_cidr:
19 type: string
20 description: CIDR of the OAM ONAP network
21
Gary Wu60dd0d82018-01-18 14:54:47 -080022 ubuntu_1604_image:
23 type: string
24 description: Name of the Ubuntu 16.04 image
25
Gary Wu60dd0d82018-01-18 14:54:47 -080026 rancher_vm_flavor:
27 type: string
Gary Wu11c98742018-05-02 16:19:04 -070028 description: VM flavor for Rancher
Gary Wu60dd0d82018-01-18 14:54:47 -080029
30 k8s_vm_flavor:
31 type: string
Gary Wu11c98742018-05-02 16:19:04 -070032 description: VM flavor for k8s hosts
33
34 integration_override_yaml:
35 type: string
36 description: Content for integration_override.yaml
Gary Wu60dd0d82018-01-18 14:54:47 -080037
Gary Wu87aa8b52018-08-09 08:10:24 -070038 integration_gerrit_branch:
Gary Wu81836d22018-06-22 13:48:50 -070039 type: string
40 default: "master"
41
Gary Wu87aa8b52018-08-09 08:10:24 -070042 integration_gerrit_refspec:
43 type: string
44 default: "refs/heads/master"
45
46 oom_gerrit_branch:
47 type: string
48 default: "master"
49
50 oom_gerrit_refspec:
Gary Wu81836d22018-06-22 13:48:50 -070051 type: string
52 default: "refs/heads/master"
53
54 docker_manifest:
55 type: string
Gary Wu87aa8b52018-08-09 08:10:24 -070056 default: ""
Gary Wu81836d22018-06-22 13:48:50 -070057
gwu10db4622018-07-17 22:11:39 -070058 key_name:
59 type: string
60 default: "onap_key"
61
Gary Wu7a04b3d2018-08-15 12:31:46 -070062 docker_version:
63 type: string
64 default: "17.03"
65
66 rancher_version:
67 type: string
68 default: "1.6.18"
69
70 rancher_agent_version:
71 type: string
72 default: "1.2.10"
73
74 kubectl_version:
75 type: string
76 default: "1.8.10"
77
78 helm_version:
79 type: string
80 default: "2.9.1"
81
Gary Wuccd529b2018-01-16 18:31:01 -080082resources:
Gary Wuc98156d2018-01-18 12:03:26 -080083 random-str:
84 type: OS::Heat::RandomString
85 properties:
86 length: 4
87
Gary Wubc11e5d2018-02-07 10:23:27 -080088 # ONAP security group
89 onap_sg:
90 type: OS::Neutron::SecurityGroup
91 properties:
92 name:
93 str_replace:
94 template: base_rand
95 params:
96 base: onap_sg
97 rand: { get_resource: random-str }
98 description: security group used by ONAP
99 rules:
100 # All egress traffic
101 - direction: egress
102 ethertype: IPv4
103 - direction: egress
104 ethertype: IPv6
105 # ingress traffic
106 # ICMP
107 - protocol: icmp
108 - protocol: udp
109 port_range_min: 1
110 port_range_max: 65535
111 - protocol: tcp
112 port_range_min: 1
113 port_range_max: 65535
114
115
Gary Wu52dfdcb2018-01-25 11:02:48 -0800116 # ONAP management private network
117 oam_network:
118 type: OS::Neutron::Net
119 properties:
120 name:
121 str_replace:
122 template: oam_network_rand
123 params:
124 rand: { get_resource: random-str }
125
126 oam_subnet:
127 type: OS::Neutron::Subnet
128 properties:
129 name:
130 str_replace:
131 template: oam_network_rand
132 params:
133 rand: { get_resource: random-str }
134 network_id: { get_resource: oam_network }
135 cidr: { get_param: oam_network_cidr }
Gary Wu14a6b302018-05-01 15:59:28 -0700136 dns_nameservers: [ "8.8.8.8" ]
Gary Wu52dfdcb2018-01-25 11:02:48 -0800137
138 router:
139 type: OS::Neutron::Router
140 properties:
eHanan97b7a9c2018-09-05 14:09:19 +0100141 name:
142 list_join: ['-', [{ get_param: 'OS::stack_name' }, 'router']]
Gary Wu52dfdcb2018-01-25 11:02:48 -0800143 external_gateway_info:
144 network: { get_param: public_net_id }
145
146 router_interface:
147 type: OS::Neutron::RouterInterface
148 properties:
149 router_id: { get_resource: router }
150 subnet_id: { get_resource: oam_subnet }
151
Gary Wu374498a2018-02-06 17:31:04 -0800152 rancher_private_port:
153 type: OS::Neutron::Port
154 properties:
155 network: { get_resource: oam_network }
156 fixed_ips: [{"subnet": { get_resource: oam_subnet }}]
Gary Wubc11e5d2018-02-07 10:23:27 -0800157 security_groups:
158 - { get_resource: onap_sg }
Gary Wu374498a2018-02-06 17:31:04 -0800159
160 rancher_floating_ip:
161 type: OS::Neutron::FloatingIP
162 properties:
163 floating_network_id: { get_param: public_net_id }
164 port_id: { get_resource: rancher_private_port }
165
Gary Wuccd529b2018-01-16 18:31:01 -0800166 rancher_vm:
167 type: OS::Nova::Server
168 properties:
eHanan97b7a9c2018-09-05 14:09:19 +0100169 name:
170 list_join: ['-', [{ get_param: 'OS::stack_name' }, 'rancher']]
Gary Wu558ac6e2018-01-19 14:53:12 -0800171 image: { get_param: ubuntu_1604_image }
Gary Wu60dd0d82018-01-18 14:54:47 -0800172 flavor: { get_param: rancher_vm_flavor }
gwu10db4622018-07-17 22:11:39 -0700173 key_name: { get_param: key_name }
Gary Wuccd529b2018-01-16 18:31:01 -0800174 networks:
Gary Wu374498a2018-02-06 17:31:04 -0800175 - port: { get_resource: rancher_private_port }
Gary Wuccd529b2018-01-16 18:31:01 -0800176 user_data_format: RAW
177 user_data:
178 str_replace:
Gary Wu1ff56672018-01-17 20:51:45 -0800179 template:
180 get_file: rancher_vm_entrypoint.sh
Gary Wu14a6b302018-05-01 15:59:28 -0700181 params:
Gary Wu14a6b302018-05-01 15:59:28 -0700182 __docker_proxy__: { get_param: docker_proxy }
183 __apt_proxy__: { get_param: apt_proxy }
184 __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] }
Gary Wuad513722018-07-26 13:08:47 -0700185 __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] }
Gary Wu11c98742018-05-02 16:19:04 -0700186 __integration_override_yaml__: { get_param: integration_override_yaml }
Gary Wu87aa8b52018-08-09 08:10:24 -0700187 __integration_gerrit_branch__: { get_param: integration_gerrit_branch }
188 __integration_gerrit_refspec__: { get_param: integration_gerrit_refspec }
189 __oom_gerrit_branch__: { get_param: oom_gerrit_branch }
190 __oom_gerrit_refspec__: { get_param: oom_gerrit_refspec }
Gary Wu81836d22018-06-22 13:48:50 -0700191 __docker_manifest__: { get_param: docker_manifest }
Gary Wu7a04b3d2018-08-15 12:31:46 -0700192 __docker_version__: { get_param: docker_version }
193 __rancher_version__: { get_param: rancher_version }
194 __rancher_agent_version__: { get_param: rancher_agent_version }
195 __kubectl_version__: { get_param: kubectl_version }
196 __helm_version__: { get_param: helm_version }
Gary Wu978171e2018-07-24 11:56:01 -0700197 __public_net_id__: { get_param: public_net_id }
198 __oam_network_cidr__: { get_param: oam_network_cidr }
Gary Wu11c98742018-05-02 16:19:04 -0700199 __oam_network_id__: { get_resource: oam_network }
200 __oam_subnet_id__: { get_resource: oam_subnet }
Gary Wu0a671622018-05-14 12:59:03 -0700201 __k8s_1_vm_ip__: { get_attr: [k8s_1_floating_ip, floating_ip_address] }
Gary Wu14a6b302018-05-01 15:59:28 -0700202 __k8s_vm_ips__: [
203 get_attr: [k8s_1_floating_ip, floating_ip_address],
204 get_attr: [k8s_2_floating_ip, floating_ip_address],
205 get_attr: [k8s_3_floating_ip, floating_ip_address],
206 get_attr: [k8s_4_floating_ip, floating_ip_address],
Gary Wu4d2cfb62018-09-07 09:05:33 -0700207 get_attr: [k8s_5_floating_ip, floating_ip_address],
Gary Wu0bf673e2018-09-18 08:24:33 -0700208 get_attr: [k8s_6_floating_ip, floating_ip_address],
Gary Wu14a6b302018-05-01 15:59:28 -0700209 ]
Gary Wuad513722018-07-26 13:08:47 -0700210 __k8s_private_ips__: [
211 get_attr: [k8s_1_floating_ip, fixed_ip_address],
212 get_attr: [k8s_2_floating_ip, fixed_ip_address],
213 get_attr: [k8s_3_floating_ip, fixed_ip_address],
214 get_attr: [k8s_4_floating_ip, fixed_ip_address],
Gary Wu4d2cfb62018-09-07 09:05:33 -0700215 get_attr: [k8s_5_floating_ip, fixed_ip_address],
Gary Wu0bf673e2018-09-18 08:24:33 -0700216 get_attr: [k8s_6_floating_ip, fixed_ip_address],
Gary Wuad513722018-07-26 13:08:47 -0700217 ]
Gary Wu14a6b302018-05-01 15:59:28 -0700218 k8s_1_private_port:
Gary Wu52dfdcb2018-01-25 11:02:48 -0800219 type: OS::Neutron::Port
220 properties:
221 network: { get_resource: oam_network }
222 fixed_ips: [{"subnet": { get_resource: oam_subnet }}]
Gary Wubc11e5d2018-02-07 10:23:27 -0800223 security_groups:
224 - { get_resource: onap_sg }
Gary Wu52dfdcb2018-01-25 11:02:48 -0800225
Gary Wu14a6b302018-05-01 15:59:28 -0700226 k8s_1_floating_ip:
Gary Wu52dfdcb2018-01-25 11:02:48 -0800227 type: OS::Neutron::FloatingIP
228 properties:
229 floating_network_id: { get_param: public_net_id }
Gary Wu14a6b302018-05-01 15:59:28 -0700230 port_id: { get_resource: k8s_1_private_port }
Gary Wu52dfdcb2018-01-25 11:02:48 -0800231
Gary Wu14a6b302018-05-01 15:59:28 -0700232 k8s_1_vm:
Gary Wuccd529b2018-01-16 18:31:01 -0800233 type: OS::Nova::Server
234 properties:
eHanan97b7a9c2018-09-05 14:09:19 +0100235 name:
236 list_join: ['-', [ { get_param: 'OS::stack_name' }, 'k8s_1']]
Gary Wu558ac6e2018-01-19 14:53:12 -0800237 image: { get_param: ubuntu_1604_image }
Gary Wu60dd0d82018-01-18 14:54:47 -0800238 flavor: { get_param: k8s_vm_flavor }
gwu10db4622018-07-17 22:11:39 -0700239 key_name: { get_param: key_name }
Gary Wuccd529b2018-01-16 18:31:01 -0800240 networks:
Gary Wu14a6b302018-05-01 15:59:28 -0700241 - port: { get_resource: k8s_1_private_port }
Gary Wuccd529b2018-01-16 18:31:01 -0800242 user_data_format: RAW
243 user_data:
244 str_replace:
245 params:
246 __docker_proxy__: { get_param: docker_proxy }
247 __apt_proxy__: { get_param: apt_proxy }
Gary Wu7a04b3d2018-08-15 12:31:46 -0700248 __docker_version__: { get_param: docker_version }
Gary Wu5d325d02018-02-06 21:21:31 -0800249 __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] }
Gary Wuad513722018-07-26 13:08:47 -0700250 __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] }
Gary Wu14a6b302018-05-01 15:59:28 -0700251 template:
252 get_file: k8s_vm_entrypoint.sh
253
254 k8s_2_private_port:
255 type: OS::Neutron::Port
256 properties:
257 network: { get_resource: oam_network }
258 fixed_ips: [{"subnet": { get_resource: oam_subnet }}]
259 security_groups:
260 - { get_resource: onap_sg }
261
262 k8s_2_floating_ip:
263 type: OS::Neutron::FloatingIP
264 properties:
265 floating_network_id: { get_param: public_net_id }
266 port_id: { get_resource: k8s_2_private_port }
267
268 k8s_2_vm:
269 type: OS::Nova::Server
270 properties:
eHanan97b7a9c2018-09-05 14:09:19 +0100271 name:
272 list_join: ['-', [ { get_param: 'OS::stack_name' }, 'k8s_2']]
Gary Wu14a6b302018-05-01 15:59:28 -0700273 image: { get_param: ubuntu_1604_image }
274 flavor: { get_param: k8s_vm_flavor }
gwu10db4622018-07-17 22:11:39 -0700275 key_name: { get_param: key_name }
Gary Wu14a6b302018-05-01 15:59:28 -0700276 networks:
277 - port: { get_resource: k8s_2_private_port }
278 user_data_format: RAW
279 user_data:
280 str_replace:
281 params:
Gary Wu14a6b302018-05-01 15:59:28 -0700282 __docker_proxy__: { get_param: docker_proxy }
283 __apt_proxy__: { get_param: apt_proxy }
Gary Wu7a04b3d2018-08-15 12:31:46 -0700284 __docker_version__: { get_param: docker_version }
Gary Wu14a6b302018-05-01 15:59:28 -0700285 __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] }
Gary Wuad513722018-07-26 13:08:47 -0700286 __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] }
Gary Wu14a6b302018-05-01 15:59:28 -0700287 template:
288 get_file: k8s_vm_entrypoint.sh
289
290 k8s_3_private_port:
291 type: OS::Neutron::Port
292 properties:
293 network: { get_resource: oam_network }
294 fixed_ips: [{"subnet": { get_resource: oam_subnet }}]
295 security_groups:
296 - { get_resource: onap_sg }
297
298 k8s_3_floating_ip:
299 type: OS::Neutron::FloatingIP
300 properties:
301 floating_network_id: { get_param: public_net_id }
302 port_id: { get_resource: k8s_3_private_port }
303
304 k8s_3_vm:
305 type: OS::Nova::Server
306 properties:
eHanan97b7a9c2018-09-05 14:09:19 +0100307 name:
308 list_join: ['-', [ { get_param: 'OS::stack_name' }, 'k8s_3']]
Gary Wu14a6b302018-05-01 15:59:28 -0700309 image: { get_param: ubuntu_1604_image }
310 flavor: { get_param: k8s_vm_flavor }
gwu10db4622018-07-17 22:11:39 -0700311 key_name: { get_param: key_name }
Gary Wu14a6b302018-05-01 15:59:28 -0700312 networks:
313 - port: { get_resource: k8s_3_private_port }
314 user_data_format: RAW
315 user_data:
316 str_replace:
317 params:
Gary Wu14a6b302018-05-01 15:59:28 -0700318 __docker_proxy__: { get_param: docker_proxy }
319 __apt_proxy__: { get_param: apt_proxy }
Gary Wu7a04b3d2018-08-15 12:31:46 -0700320 __docker_version__: { get_param: docker_version }
Gary Wu14a6b302018-05-01 15:59:28 -0700321 __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] }
Gary Wuad513722018-07-26 13:08:47 -0700322 __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] }
Gary Wu14a6b302018-05-01 15:59:28 -0700323 template:
324 get_file: k8s_vm_entrypoint.sh
325
326 k8s_4_private_port:
327 type: OS::Neutron::Port
328 properties:
329 network: { get_resource: oam_network }
330 fixed_ips: [{"subnet": { get_resource: oam_subnet }}]
331 security_groups:
332 - { get_resource: onap_sg }
333
334 k8s_4_floating_ip:
335 type: OS::Neutron::FloatingIP
336 properties:
337 floating_network_id: { get_param: public_net_id }
338 port_id: { get_resource: k8s_4_private_port }
339
340 k8s_4_vm:
341 type: OS::Nova::Server
342 properties:
eHanan97b7a9c2018-09-05 14:09:19 +0100343 name:
344 list_join: ['-', [ { get_param: 'OS::stack_name' }, 'k8s_4']]
Gary Wu14a6b302018-05-01 15:59:28 -0700345 image: { get_param: ubuntu_1604_image }
346 flavor: { get_param: k8s_vm_flavor }
gwu10db4622018-07-17 22:11:39 -0700347 key_name: { get_param: key_name }
Gary Wu14a6b302018-05-01 15:59:28 -0700348 networks:
349 - port: { get_resource: k8s_4_private_port }
350 user_data_format: RAW
351 user_data:
352 str_replace:
353 params:
Gary Wu14a6b302018-05-01 15:59:28 -0700354 __docker_proxy__: { get_param: docker_proxy }
355 __apt_proxy__: { get_param: apt_proxy }
Gary Wu7a04b3d2018-08-15 12:31:46 -0700356 __docker_version__: { get_param: docker_version }
Gary Wu14a6b302018-05-01 15:59:28 -0700357 __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] }
Gary Wuad513722018-07-26 13:08:47 -0700358 __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] }
Gary Wu14a6b302018-05-01 15:59:28 -0700359 template:
360 get_file: k8s_vm_entrypoint.sh
361
Gary Wu4d2cfb62018-09-07 09:05:33 -0700362 k8s_5_private_port:
363 type: OS::Neutron::Port
364 properties:
365 network: { get_resource: oam_network }
366 fixed_ips: [{"subnet": { get_resource: oam_subnet }}]
367 security_groups:
368 - { get_resource: onap_sg }
369
370 k8s_5_floating_ip:
371 type: OS::Neutron::FloatingIP
372 properties:
373 floating_network_id: { get_param: public_net_id }
374 port_id: { get_resource: k8s_5_private_port }
375
376 k8s_5_vm:
377 type: OS::Nova::Server
378 properties:
eHanan97b7a9c2018-09-05 14:09:19 +0100379 name:
380 list_join: ['-', [ { get_param: 'OS::stack_name' }, 'k8s_5']]
Gary Wu4d2cfb62018-09-07 09:05:33 -0700381 image: { get_param: ubuntu_1604_image }
382 flavor: { get_param: k8s_vm_flavor }
383 key_name: { get_param: key_name }
384 networks:
385 - port: { get_resource: k8s_5_private_port }
386 user_data_format: RAW
387 user_data:
388 str_replace:
389 params:
390 __docker_proxy__: { get_param: docker_proxy }
391 __apt_proxy__: { get_param: apt_proxy }
392 __docker_version__: { get_param: docker_version }
393 __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] }
394 __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] }
395 template:
396 get_file: k8s_vm_entrypoint.sh
397
Gary Wu0bf673e2018-09-18 08:24:33 -0700398 k8s_6_private_port:
399 type: OS::Neutron::Port
400 properties:
401 network: { get_resource: oam_network }
402 fixed_ips: [{"subnet": { get_resource: oam_subnet }}]
403 security_groups:
404 - { get_resource: onap_sg }
405
406 k8s_6_floating_ip:
407 type: OS::Neutron::FloatingIP
408 properties:
409 floating_network_id: { get_param: public_net_id }
410 port_id: { get_resource: k8s_6_private_port }
411
412 k8s_6_vm:
413 type: OS::Nova::Server
414 properties:
415 name:
416 list_join: ['-', [ { get_param: 'OS::stack_name' }, 'k8s_6']]
417 image: { get_param: ubuntu_1604_image }
418 flavor: { get_param: k8s_vm_flavor }
419 key_name: { get_param: key_name }
420 networks:
421 - port: { get_resource: k8s_6_private_port }
422 user_data_format: RAW
423 user_data:
424 str_replace:
425 params:
426 __docker_proxy__: { get_param: docker_proxy }
427 __apt_proxy__: { get_param: apt_proxy }
428 __docker_version__: { get_param: docker_version }
429 __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] }
430 __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] }
431 template:
432 get_file: k8s_vm_entrypoint.sh
433
Gary Wu14ee41d2018-01-19 15:03:59 -0800434outputs:
Gary Wu61034082018-01-22 12:48:50 -0800435 rancher_vm_ip:
436 description: The IP address of the rancher instance
Gary Wu5d325d02018-02-06 21:21:31 -0800437 value: { get_attr: [rancher_floating_ip, floating_ip_address] }
Gary Wu61034082018-01-22 12:48:50 -0800438
Gary Wu36e42dd2018-05-03 07:29:53 -0700439 k8s_1_vm_ip:
440 description: The IP address of the k8s_1 instance
441 value: { get_attr: [k8s_1_floating_ip, floating_ip_address] }
442
443 k8s_2_vm_ip:
444 description: The IP address of the k8s_2 instance
445 value: { get_attr: [k8s_2_floating_ip, floating_ip_address] }
446
447 k8s_3_vm_ip:
448 description: The IP address of the k8s_3 instance
449 value: { get_attr: [k8s_3_floating_ip, floating_ip_address] }
450
451 k8s_4_vm_ip:
452 description: The IP address of the k8s_4 instance
453 value: { get_attr: [k8s_4_floating_ip, floating_ip_address] }
454
Gary Wu4d2cfb62018-09-07 09:05:33 -0700455 k8s_5_vm_ip:
456 description: The IP address of the k8s_5 instance
457 value: { get_attr: [k8s_5_floating_ip, floating_ip_address] }
458
Gary Wu0bf673e2018-09-18 08:24:33 -0700459 k8s_6_vm_ip:
460 description: The IP address of the k8s_6 instance
461 value: { get_attr: [k8s_6_floating_ip, floating_ip_address] }
462