blob: 2551d12b2c9d390b2737cbb8d3728da6bce6c2c0 [file] [log] [blame]
Victor Ryzhenkina95d1732017-11-16 19:02:19 +04001# This environment requires 50.5 GB of RAM and 270GB of Storage. Run with caution.
2{% set REPOSITORY_SUITE = os_env('REPOSITORY_SUITE', 'testing') %}
3
4{% import 'k8s-ha-contrail/underlay--meta-data.yaml' as CLOUDINIT_META_DATA with context %}
5{% import 'k8s-ha-contrail/underlay--user-data-cfg01.yaml' as CLOUDINIT_USER_DATA_CFG01 with context %}
6{% import 'k8s-ha-contrail/underlay--user-data1604.yaml' as CLOUDINIT_USER_DATA_1604 with context %}
7{% import 'k8s-ha-contrail/underlay--user-data1404.yaml' as CLOUDINIT_USER_DATA_1404 with context %}
8
9---
10aliases:
11 - &interface_model {{ os_env('INTERFACE_MODEL', 'virtio') }}
12 - &cloudinit_meta_data {{ CLOUDINIT_META_DATA }}
13 - &cloudinit_user_data_cfg01 {{ CLOUDINIT_USER_DATA_CFG01 }}
14 - &cloudinit_user_data_1604 {{ CLOUDINIT_USER_DATA_1604 }}
15 - &cloudinit_user_data_1404 {{ CLOUDINIT_USER_DATA_1404 }}
16
17{% set LAB_CONFIG_NAME = os_env('LAB_CONFIG_NAME', 'k8s-ha-contrail') %}
18{% set DOMAIN_NAME = os_env('DOMAIN_NAME', LAB_CONFIG_NAME) + '.local' %}
19{% set HOSTNAME_CFG01 = os_env('HOSTNAME_CFG01', 'cfg01.' + DOMAIN_NAME) %}
20{% set HOSTNAME_CTL01 = os_env('HOSTNAME_CTL01', 'ctl01.' + DOMAIN_NAME) %}
21{% set HOSTNAME_CTL02 = os_env('HOSTNAME_CTL02', 'ctl02.' + DOMAIN_NAME) %}
22{% set HOSTNAME_CTL03 = os_env('HOSTNAME_CTL03', 'ctl03.' + DOMAIN_NAME) %}
23{% set HOSTNAME_CMP01 = os_env('HOSTNAME_CMP01', 'cmp0.' + DOMAIN_NAME) %}
24{% set HOSTNAME_CMP02 = os_env('HOSTNAME_CMP02', 'cmp1.' + DOMAIN_NAME) %}
25{% set HOSTNAME_NTW01 = os_env('HOSTNAME_NTW01', 'ntw01.' + DOMAIN_NAME) %}
26{% set HOSTNAME_NTW02 = os_env('HOSTNAME_NTW02', 'ntw02.' + DOMAIN_NAME) %}
27{% set HOSTNAME_NTW03 = os_env('HOSTNAME_NTW03', 'ntw03.' + DOMAIN_NAME) %}
28{% set HOSTNAME_VSRX01 = os_env('HOSTNAME_VSRX01', 'vsrx01.' + DOMAIN_NAME) %}
29
30template:
31 devops_settings:
32 env_name: {{ os_env('ENV_NAME', 'k8s-ha-contrail_' + REPOSITORY_SUITE + "_" + os_env('BUILD_NUMBER', '')) }}
33
34 address_pools:
35
36 private-pool01:
37 net: {{ os_env('PRIVATE_ADDRESS_POOL01', '172.16.10.0/24:24') }}
38 params:
39 ip_reserved:
40 gateway: +1
41 l2_network_device: +1
42 default_{{ HOSTNAME_CFG01 }}: +100
43 default_{{ HOSTNAME_CTL01 }}: +101
44 default_{{ HOSTNAME_CTL02 }}: +102
45 default_{{ HOSTNAME_CTL03 }}: +103
46 default_{{ HOSTNAME_CMP01 }}: +105
47 default_{{ HOSTNAME_CMP02 }}: +106
48 default_{{ HOSTNAME_NTW01 }}: +110
49 default_{{ HOSTNAME_NTW02 }}: +111
50 default_{{ HOSTNAME_NTW03 }}: +112
51 default_{{ HOSTNAME_VSRX01 }}: +90
52 ip_ranges:
53 dhcp: [+90, -10]
54
55 public-pool01:
56 net: {{ os_env('PUBLIC_ADDRESS_POOL01', '192.168.10.0/24:24') }}
57 params:
58 ip_reserved:
59 gateway: +1
60 l2_network_device: +1
61 default_{{ HOSTNAME_CFG01 }}: +100
62 default_{{ HOSTNAME_CTL01 }}: +101
63 default_{{ HOSTNAME_CTL02 }}: +102
64 default_{{ HOSTNAME_CTL03 }}: +103
65 default_{{ HOSTNAME_CMP01 }}: +105
66 default_{{ HOSTNAME_CMP02 }}: +106
67 default_{{ HOSTNAME_NTW01 }}: +110
68 default_{{ HOSTNAME_NTW02 }}: +111
69 default_{{ HOSTNAME_NTW03 }}: +112
70 default_{{ HOSTNAME_VSRX01 }}: +90
71 ip_ranges:
72 dhcp: [+90, -10]
73
74 admin-pool01:
75 net: {{ os_env('ADMIN_ADDRESS_POOL01', '10.70.0.0/24:24') }}
76 params:
77 ip_reserved:
78 gateway: +1
79 l2_network_device: +1
80 default_{{ HOSTNAME_CFG01 }}: +15
81 default_{{ HOSTNAME_CTL01 }}: +101
82 default_{{ HOSTNAME_CTL02 }}: +102
83 default_{{ HOSTNAME_CTL03 }}: +103
84 default_{{ HOSTNAME_CMP01 }}: +105
85 default_{{ HOSTNAME_CMP02 }}: +106
86 default_{{ HOSTNAME_NTW01 }}: +110
87 default_{{ HOSTNAME_NTW02 }}: +111
88 default_{{ HOSTNAME_NTW03 }}: +112
89 default_{{ HOSTNAME_VSRX01 }}: +90
90 ip_ranges:
91 dhcp: [+10, -10]
92
93 groups:
94 - name: default
95 driver:
96 name: devops.driver.libvirt
97 params:
98 connection_string: !os_env CONNECTION_STRING, qemu:///system
99 storage_pool_name: !os_env STORAGE_POOL_NAME, default
100 stp: True
101 hpet: False
102 enable_acpi: true
103 use_host_cpu: !os_env DRIVER_USE_HOST_CPU, true
104 use_hugepages: !os_env DRIVER_USE_HUGEPAGES, false
105
106 network_pools:
107 private: private-pool01
108 public: public-pool01
109 admin: admin-pool01
110
111 l2_network_devices:
112 private:
113 address_pool: private-pool01
114 dhcp: true
115
116 public:
117 address_pool: public-pool01
118 dhcp: true
119 forward:
120 mode: nat
121
122 admin:
123 address_pool: admin-pool01
124 dhcp: true
125
126 group_volumes:
127 - name: cloudimage1604 # This name is used for 'backing_store' option for node volumes.
Dennis Dmitrievf00a3842018-01-24 16:44:26 +0200128 source_image: !os_env IMAGE_PATH1604 # https://cloud-images.ubuntu.com/xenial/current/xenial-server-cloudimg-amd64-disk1.img
129 format: qcow2
130
131 - name: cfg01_day01_image # Pre-configured day01 image
132 source_image: {{ os_env('IMAGE_PATH_CFG01_DAY01', os_env('IMAGE_PATH1604')) }} # http://images.mirantis.com/cfg01-day01.qcow2 or fallback to IMAGE_PATH1604
Victor Ryzhenkina95d1732017-11-16 19:02:19 +0400133 format: qcow2
134
135 - name: cloudimage1404
136 source_image: !os_env IMAGE_PATH1404
137 format: qcow2
138
139 - name: vsrx_image
140 source_image: !os_env IMAGE_VSRX
141 format: qcow2
142
143 nodes:
144 - name: {{ HOSTNAME_CFG01 }}
145 role: salt_master
146 params:
147 vcpu: !os_env SLAVE_NODE_CPU, 2
148 memory: !os_env SLAVE_NODE_MEMORY, 4096
149 boot:
150 - hd
151 cloud_init_volume_name: iso
152 cloud_init_iface_up: ens3
153 volumes:
154 - name: system
Dennis Dmitrieveb466d42018-01-25 04:13:55 +0200155 capacity: !os_env NODE_VOLUME_SIZE, 150
Dennis Dmitrievf00a3842018-01-24 16:44:26 +0200156 backing_store: cfg01_day01_image
Victor Ryzhenkina95d1732017-11-16 19:02:19 +0400157 format: qcow2
158 - name: iso # Volume with name 'iso' will be used
159 # for store image with cloud-init metadata.
160 capacity: 1
161 format: raw
162 device: cdrom
163 bus: ide
164 cloudinit_meta_data: *cloudinit_meta_data
165 cloudinit_user_data: *cloudinit_user_data_cfg01
166
167 interfaces:
168 - label: ens3
169 l2_network_device: public
170 interface_model: *interface_model
171 - label: ens4
172 l2_network_device: private
173 interface_model: *interface_model
174 - label: ens5
175 l2_network_device: admin
176 interface_model: *interface_model
177
178 network_config:
179 ens3:
180 networks:
181 - public
182 ens4:
183 networks:
184 - private
185 ens5:
186 networks:
187 - admin
188
189 - name: {{ HOSTNAME_CTL01 }}
190 role: k8s_controller
191 params:
192 vcpu: !os_env SLAVE_NODE_CPU, 2
193 memory: !os_env SLAVE_NODE_MEMORY, 4096
194 boot:
195 - hd
196 cloud_init_volume_name: iso
197 cloud_init_iface_up: ens3
198 volumes:
199 - name: system
200 capacity: !os_env NODE_VOLUME_SIZE, 20
201 backing_store: cloudimage1604
202 format: qcow2
203 - name: cinder
204 capacity: 50
205 format: qcow2
206 - name: iso # Volume with name 'iso' will be used
207 # for store image with cloud-init metadata.
208 capacity: 1
209 format: raw
210 device: cdrom
211 bus: ide
212 cloudinit_meta_data: *cloudinit_meta_data
213 cloudinit_user_data: *cloudinit_user_data_1604
214
215 interfaces: &interfaces
216 - label: ens3
217 l2_network_device: public
218 interface_model: *interface_model
219 - label: ens4
220 l2_network_device: private
221 interface_model: *interface_model
222 - label: ens5
223 l2_network_device: admin
224 interface_model: *interface_model
225 network_config: &network_config
226 ens3:
227 networks:
228 - public
229 ens4:
230 networks:
231 - private
232 ens5:
233 networks:
234 - admin
235
236 - name: {{ HOSTNAME_CTL02 }}
237 role: salt_minion
238 params:
239 vcpu: !os_env SLAVE_NODE_CPU, 2
240 memory: !os_env SLAVE_NODE_MEMORY, 4096
241 boot:
242 - hd
243 cloud_init_volume_name: iso
244 cloud_init_iface_up: ens3
245 volumes:
246 - name: system
247 capacity: !os_env NODE_VOLUME_SIZE, 20
248 backing_store: cloudimage1604
249 format: qcow2
250 - name: cinder
251 capacity: 50
252 format: qcow2
253 - name: iso # Volume with name 'iso' will be used
254 # for store image with cloud-init metadata.
255 capacity: 1
256 format: raw
257 device: cdrom
258 bus: ide
259 cloudinit_meta_data: *cloudinit_meta_data
260 cloudinit_user_data: *cloudinit_user_data_1604
261
262 interfaces: *interfaces
263 network_config: *network_config
264
265 - name: {{ HOSTNAME_CTL03 }}
266 role: salt_minion
267 params:
268 vcpu: !os_env SLAVE_NODE_CPU, 2
269 memory: !os_env SLAVE_NODE_MEMORY, 4096
270 boot:
271 - hd
272 cloud_init_volume_name: iso
273 cloud_init_iface_up: ens3
274 volumes:
275 - name: system
276 capacity: !os_env NODE_VOLUME_SIZE, 20
277 backing_store: cloudimage1604
278 format: qcow2
279 - name: cinder
280 capacity: 50
281 format: qcow2
282 - name: iso # Volume with name 'iso' will be used
283 # for store image with cloud-init metadata.
284 capacity: 1
285 format: raw
286 device: cdrom
287 bus: ide
288 cloudinit_meta_data: *cloudinit_meta_data
289 cloudinit_user_data: *cloudinit_user_data_1604
290
291 interfaces: *interfaces
292 network_config: *network_config
293
294 - name: {{ HOSTNAME_CMP01 }}
295 role: salt_minion
296 params:
297 vcpu: !os_env SLAVE_NODE_CPU, 2
298 memory: !os_env SLAVE_NODE_MEMORY, 4096
299 boot:
300 - hd
301 cloud_init_volume_name: iso
302 cloud_init_iface_up: ens3
303 volumes:
304 - name: system
305 capacity: !os_env NODE_VOLUME_SIZE, 20
306 backing_store: cloudimage1604
307 format: qcow2
308 - name: iso # Volume with name 'iso' will be used
309 # for store image with cloud-init metadata.
310 capacity: 1
311 format: raw
312 device: cdrom
313 bus: ide
314 cloudinit_meta_data: *cloudinit_meta_data
315 cloudinit_user_data: *cloudinit_user_data_1604
316
317 interfaces: *interfaces
318 network_config: *network_config
319
320 - name: {{ HOSTNAME_CMP02 }}
321 role: salt_minion
322 params:
323 vcpu: !os_env SLAVE_NODE_CPU, 2
324 memory: !os_env SLAVE_NODE_MEMORY, 4096
325 boot:
326 - hd
327 cloud_init_volume_name: iso
328 cloud_init_iface_up: ens3
329 volumes:
330 - name: system
331 capacity: !os_env NODE_VOLUME_SIZE, 20
332 backing_store: cloudimage1604
333 format: qcow2
334 - name: iso # Volume with name 'iso' will be used
335 # for store image with cloud-init metadata.
336 capacity: 1
337 format: raw
338 device: cdrom
339 bus: ide
340 cloudinit_meta_data: *cloudinit_meta_data
341 cloudinit_user_data: *cloudinit_user_data_1604
342
343 interfaces: *interfaces
344 network_config: *network_config
345
346 - name: {{ HOSTNAME_NTW01 }}
347 role: salt_minion
348 params:
349 vcpu: !os_env SLAVE_NODE_CPU, 2
350 memory: !os_env SLAVE_NODE_MEMORY, 8192
351 boot:
352 - hd
353 cloud_init_volume_name: iso
354 cloud_init_iface_up: ens3
355 volumes:
356 - name: system
357 capacity: !os_env NODE_VOLUME_SIZE, 20
358 backing_store: cloudimage1404
359 format: qcow2
360 - name: iso # Volume with name 'iso' will be used
361 # for store image with cloud-init metadata.
362 capacity: 1
363 format: raw
364 device: cdrom
365 bus: ide
366 cloudinit_meta_data: *cloudinit_meta_data
367 cloudinit_user_data: *cloudinit_user_data_1404
368
369 interfaces: *interfaces
370 network_config: *network_config
371
372 - name: {{ HOSTNAME_NTW02 }}
373 role: salt_minion
374 params:
375 vcpu: !os_env SLAVE_NODE_CPU, 2
376 memory: !os_env SLAVE_NODE_MEMORY, 8192
377 boot:
378 - hd
379 cloud_init_volume_name: iso
380 cloud_init_iface_up: ens3
381 volumes:
382 - name: system
383 capacity: !os_env NODE_VOLUME_SIZE, 20
384 backing_store: cloudimage1404
385 format: qcow2
386 - name: iso # Volume with name 'iso' will be used
387 # for store image with cloud-init metadata.
388 capacity: 1
389 format: raw
390 device: cdrom
391 bus: ide
392 cloudinit_meta_data: *cloudinit_meta_data
393 cloudinit_user_data: *cloudinit_user_data_1404
394
395 interfaces: *interfaces
396 network_config: *network_config
397
398 - name: {{ HOSTNAME_NTW03 }}
399 role: salt_minion
400 params:
401 vcpu: !os_env SLAVE_NODE_CPU, 2
402 memory: !os_env SLAVE_NODE_MEMORY, 8192
403 boot:
404 - hd
405 cloud_init_volume_name: iso
406 cloud_init_iface_up: ens3
407 volumes:
408 - name: system
409 capacity: !os_env NODE_VOLUME_SIZE, 20
410 backing_store: cloudimage1404
411 format: qcow2
412 - name: iso # Volume with name 'iso' will be used
413 # for store image with cloud-init metadata.
414 capacity: 1
415 format: raw
416 device: cdrom
417 bus: ide
418 cloudinit_meta_data: *cloudinit_meta_data
419 cloudinit_user_data: *cloudinit_user_data_1404
420
421 interfaces: *interfaces
422 network_config: *network_config
423
424 - name: {{ HOSTNAME_VSRX01 }}
425 role: vsrx
426 params:
427 vcpu: !os_env SLAVE_NODE_CPU, 2
428 memory: !os_env SLAVE_NODE_MEMORY, 512
429 boot:
430 - hd
431 volumes:
432 - name: system
433 capacity: !os_env NODE_VOLUME_SIZE, 10
434 backing_store: vsrx_image
435 format: qcow2
436 #- name: iso
437 #- capacity: 1
438 #- format: raw
439 #- device: cdrom
440 #- bus: ide
441 #- cloudinit_user_data: !include juniper.conf
442
443 interfaces:
444 - label: ge-0/0/0
445 l2_network_device: private
446 interface_model: *interface_model
447 mac_address: 52:54:00:4e:b4:36
448 - label: ge-0/0/1
449 l2_network_device: public
450 interface_model: *interface_model
451 mac_address: 52:54:00:e1:44:9d
452 - label: ge-0/0/2
453 l2_network_device: admin
454 interface_model: *interface_model
455 mac_address: 52:54:00:72:08:77