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