neutron/neutron/common
yatinkarel 4a06685098 [OVN] Correctly set dns_server in dhcpv4/v6 options
When ovn/dns_servers consist of IPv6 dns nameservers,
it was getting added to IPv4 dhcp options also, and due to
this an invalid nameserver(last 4 octets of an IPv6 address)
is set in the instances.

This patch filters IPv4/IPv6 dns nameservers and set
dhcpv4/dhcpv6 options accordingly.

Also when dns_nameservers are not set for IPv6 subnets,
get those from ovn/dns_servers config or system nameservers
just like it's done with the IPv4 subnets. Updated
get_system_dns_resolvers to pick both IPv4/IPv6 valid
ips, this also requires bump of oslo.utils minimum version
to 4.8.0 to use strict option for IPv4[1].

Additionally fix some unit tests which were setting IPv4 dns
nameservers on the IPv6 subnets, this is not allowed with api.

[1] https://github.com/openstack/oslo.utils/commit/3288539

Closes-Bug: #1951816
Change-Id: I9f914e721201072e43a8c6c266ed97ca85fcc13d
2022-01-06 05:02:35 +00:00
..
ovn [OVN] Correctly set dns_server in dhcpv4/v6 options 2022-01-06 05:02:35 +00:00
__init__.py Update License Headers to replace Nicira with VMware 2014-02-27 08:11:15 +00:00
_constants.py Auto-remove floating agent gw ports on net/subnet delete 2020-11-09 14:05:03 +04:00
_deprecate.py Fix flake8 N534 untranslated exception message 2018-10-19 15:46:04 -04:00
cache_utils.py Fix return correct cache when reusing port 2020-03-27 16:48:57 +04:00
config.py [goal] Deprecate the JSON formatted policy file 2021-01-08 09:10:49 +00:00
coordination.py Remove usage of six.PY2 2020-05-22 12:59:01 -04:00
eventlet_utils.py Bump pylint version to support python 3.8 2020-08-06 16:00:30 +02:00
ipv6_utils.py Adding check for IPv6 address in setup_controllers 2019-10-29 15:10:25 +00:00
profiler.py Make code follow log translation guideline 2017-08-14 02:01:48 +00:00
test_lib.py Revert "Removed test_lib module" 2015-06-29 08:27:41 +00:00
utils.py Do not announce any DNS resolver if "0.0.0.0" or "::" provided 2021-12-16 13:20:29 +00:00