Change-Id: Iffc473a4c90ff4ee8cfbcc304a3462559199fbe0
Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
{%- set gateway = ".".join([ips[0], ips[1], ips[2], "1"]) -%}
{%- endif -%}
- {#- set v=v.update(...) is unpredictable and breaks in older j2 -#}
- {%- set _ = networks.update({key: {'interface_name': interface_name,
- 'bus_addr': bus_addr,
- 'vlan': vlan,
- 'network': network,
- 'mask': mask,
- 'start': start,
- 'end': end,
- 'vip': vip,
- 'gateway': gateway
- }
- }) %}
+ {%- do networks.update({key: {'interface_name': interface_name,
+ 'bus_addr': bus_addr,
+ 'vlan': vlan,
+ 'network': network,
+ 'mask': mask,
+ 'start': start,
+ 'end': end,
+ 'vip': vip,
+ 'gateway': gateway
+ }
+ }) %}
- cidr: '{{ network }}/{{ mask }}'
gateway: '{{ gateway }}'
{#- Physical interface OS name for each network (e.g. em1, enp1s0f1) #}
{%- for role in [ctl01, cmp001] %}
{%- set node = conf.idf.fuel.network.node[role.idx] %}
- {%- set _ = role.update({
+ {%- do role.update({
'nic_mcp': node.interfaces[idx_mcp],
'nic_admin': node.interfaces[idx_admin],
'nic_mgmt': node.interfaces[idx_mgmt],