mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Fix broken IPv6 regex (#43175)
This commit is contained in:
parent
1b86d598fc
commit
42a9fb1337
1 changed files with 1 additions and 1 deletions
|
@ -291,7 +291,7 @@ class Interfaces(FactsBase):
|
||||||
# Only gets primary IPv6 addresses
|
# Only gets primary IPv6 addresses
|
||||||
def populate_ipv6_interfaces(self, data):
|
def populate_ipv6_interfaces(self, data):
|
||||||
interfaces = re.split('=+', data)[1].strip()
|
interfaces = re.split('=+', data)[1].strip()
|
||||||
matches = re.findall(r'(\S+ \S+) +[\w-]+.+\s+([\d:/]+)', interfaces, re.M)
|
matches = re.findall(r'(\S+ \S+) +[\w-]+.+\s+([\w:/]+/\d+)', interfaces, re.M)
|
||||||
for match in matches:
|
for match in matches:
|
||||||
interface = match[0]
|
interface = match[0]
|
||||||
self.facts['interfaces'][interface]['ipv6'] = list()
|
self.facts['interfaces'][interface]['ipv6'] = list()
|
||||||
|
|
Loading…
Reference in a new issue