From a7ac0fd5ceb993a8fbb256a3fd91d0d6c6531887 Mon Sep 17 00:00:00 2001 From: Gaige B Paulsen Date: Sat, 9 Nov 2024 21:43:44 -0500 Subject: T6815:Fix compatibility with 1.3-1.5 of VyOS (Step 1) (#352) * omnibus update for 1.3-1.4 (with some support for 1.5) (see contents in release fragments) --------- Co-authored-by: Om Nom --- plugins/cliconf/vyos.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'plugins/cliconf') diff --git a/plugins/cliconf/vyos.py b/plugins/cliconf/vyos.py index 7e6b0b17..5beffaa1 100644 --- a/plugins/cliconf/vyos.py +++ b/plugins/cliconf/vyos.py @@ -80,6 +80,11 @@ class Cliconf(CliconfBase): if match: device_info["network_os_version"] = match.group(1) + if device_info["network_os_version"]: + match = re.search(r"VyOS\s*(\d+\.\d+)", device_info["network_os_version"]) + if match: + device_info["network_os_major_version"] = match.group(1) + match = re.search(r"(?:HW|Hardware) model:\s*(\S+)", data) if match: device_info["network_os_model"] = match.group(1) -- cgit v1.2.3