Skip to content

Commit 49a008b

Browse files
fyanacbshewale
authored andcommitted
[adoption_osp_deploy] Add compressed IPv6 format
Add compressed IPv6 format to os_net_config_overcloud.yml.j2 for ipv6 adoption jobs. It wouldn't affect IPv4 jobs. Assisted-By: Cursor-claude-4-sonnet Signed-off-by: Fiorella Yanac <fyanac@redhat.com>
1 parent bcd55ea commit 49a008b

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

roles/adoption_osp_deploy/templates/os_net_config_overcloud.yml.j2

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,17 @@ network_config:
66
use_dhcp: false
77
dns_servers:
88
{% for _dns_ip in _dns_server | default([]) %}
9-
- {{ _dns_ip }}
9+
- {{ _dns_ip | ansible.utils.ipaddr('address') }}
1010
{% endfor %}
11-
- {{ _gateway_ip }}
11+
- {{ _gateway_ip | ansible.utils.ipaddr('address') }}
1212
domain: []
1313
addresses:
14-
- ip_netmask: {{ _ctlplane_ip }}/{{ _ctlplane_cidr }}
14+
- ip_netmask: {{ _ctlplane_ip | ansible.utils.ipaddr('address') }}/{{ _ctlplane_cidr }}
1515
{% if _stack.routes is defined %}
1616
routes:
1717
{% for route in _stack.routes %}
1818
- ip_netmask: {{ route.ip_netmask }}
19-
next_hop: {{ route.next_hop }}
19+
next_hop: {{ route.next_hop | ansible.utils.ipaddr('address') }}
2020
default: {{ route.default }}
2121
{% endfor %}
2222
{% else %}
@@ -36,12 +36,12 @@ network_config:
3636
mtu: {{ net.mtu }}
3737
vlan_id: {{ net.vlan_id }}
3838
addresses:
39-
- ip_netmask: {{ net[ip_version|default('ip_v4')] }}/{{ net[prefix_length_version|default('prefix_length_v4')] }}
39+
- ip_netmask: {{ net[ip_version|default('ip_v4')] | ansible.utils.ipaddr('address') }}/{{ net[prefix_length_version|default('prefix_length_v4')] }}
4040
{% if _stack.network_routes is defined and network_name in _stack.network_routes %}
4141
routes:
4242
{% for route in _stack.network_routes[network_name] %}
4343
- ip_netmask: {{ route.ip_netmask }}
44-
next_hop: {{ route.next_hop }}
44+
next_hop: {{ route.next_hop | ansible.utils.ipaddr('address') }}
4545
{% endfor %}
4646
{% else %}
4747
routes: []
@@ -54,7 +54,7 @@ network_config:
5454
- type: ovs_bridge
5555
name: br-baremetal
5656
addresses:
57-
- ip_netmask: {{ net[ip_version|default('ip_v4')] }}/{{ net[prefix_length_version|default('prefix_length_v4')] }}
57+
- ip_netmask: {{ net[ip_version|default('ip_v4')] | ansible.utils.ipaddr('address') }}/{{ net[prefix_length_version|default('prefix_length_v4')] }}
5858
use_dhcp: false
5959
routes: []
6060
members:

0 commit comments

Comments
 (0)