[PDF] Switch to generate_config, unify templates
[fuel.git] / mcp / scripts / virsh_net / net_mgmt.xml.j2
1 <!--
2  Copyright (c) 2017 Mirantis Inc., Enea AB and others.
3
4  All rights reserved. This program and the accompanying materials
5  are made available under the terms of the Apache License, Version 2.0
6  which accompanies this distribution, and is available at
7  http://www.apache.org/licenses/LICENSE-2.0
8 -->
9 {%- if conf.idf.net_config.mgmt is defined %}
10   {%- set mgmt_network = conf.idf.net_config.mgmt.network %}
11   {%- set mgmt_prefix = conf.idf.net_config.mgmt.mask %}
12 {%- else %}
13   {%- set mgmt_network = '172.16.10.0' %}
14   {%- set mgmt_prefix = '24' %}
15 {%- endif %}
16 <network>
17   <name>mgmt</name>
18   <bridge name="mgmt"/>
19   <ip address="{{ mgmt_network | ipaddr_index(1) }}" netmask="{{ mgmt_prefix | netmask }}"/>
20 </network>