diff options
author | Håkon Solbjørg <hakon@solbj.org> | 2023-04-02 14:57:00 +0200 |
---|---|---|
committer | Håkon Solbjørg <hakon@solbj.org> | 2023-04-02 14:57:00 +0200 |
commit | 1c443e2aa28981353fae22ff0aef6bc6b2fdcb42 (patch) | |
tree | bce85284549b2777e9fffdd078bad8e5ddd656c9 /tools | |
parent | 3cb520a4681a76fd9c6800a6bc5ac9ae7ea9918f (diff) |
fix(netbox2gondul): Give gw address prefixlen so it can be found
Diffstat (limited to 'tools')
-rw-r--r-- | tools/netbox/scripts/netbox2gondul/netbox2gondul.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/netbox/scripts/netbox2gondul/netbox2gondul.py b/tools/netbox/scripts/netbox2gondul/netbox2gondul.py index 875954f..ee6786a 100644 --- a/tools/netbox/scripts/netbox2gondul/netbox2gondul.py +++ b/tools/netbox/scripts/netbox2gondul/netbox2gondul.py @@ -116,7 +116,7 @@ class Netbox2Gondul(Script): self.log_warning(f'Network for VLAN <a href="{vlan.get_absolute_url()}">{vlan.name}</a> is missing IPv6 Prefix') try: - router = str(IPAddress.objects.get(address=gw4)) + router = str(IPAddress.objects.get(address=f"{gw4}/{subnet4.prefixlen}")) except IPAddress.DoesNotExist: self.log_warning(f'Router not found for VLAN <a href="{vlan.get_absolute_url()}">{vlan.name}</a>') router = "r1.tele" |