mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-04-02 08:43:10 +00:00
nxos_facts fix default udpate platform facts (#53795)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
This commit is contained in:
@@ -253,14 +253,7 @@ class Default(FactsBase):
|
||||
if data:
|
||||
self.facts['license_hostid'] = self.parse_license_hostid(data)
|
||||
|
||||
def parse_version(self, data):
|
||||
match = re.search(r'\s+system:\s+version\s*(\S+)', data, re.M)
|
||||
if match:
|
||||
return match.group(1)
|
||||
else:
|
||||
match = re.search(r'\s+kickstart:\s+version\s*(\S+)', data, re.M)
|
||||
if match:
|
||||
return match.group(1)
|
||||
self.facts.update(self.platform_facts())
|
||||
|
||||
def parse_serialnum(self, data):
|
||||
match = re.search(r'Processor Board ID\s*(\S+)', data, re.M)
|
||||
|
||||
Reference in New Issue
Block a user