aboutsummaryrefslogtreecommitdiffstats
path: root/tools/netbox/scripts/create-switch/create-switch.py
diff options
context:
space:
mode:
authorHåkon Solbjørg <hakon@solbj.org>2023-03-31 20:45:46 +0200
committerHåkon Solbjørg <hakon@solbj.org>2023-03-31 20:45:46 +0200
commit55fc17107e00a7de4d6181c9d2769d601b31435b (patch)
tree8bf8e3713d5bf24beec58c64ced66436955e0134 /tools/netbox/scripts/create-switch/create-switch.py
parent507a2b94d28b54756b3badbf44b229a16f27ade6 (diff)
feat(tags): Log selected uplink tag
Diffstat (limited to 'tools/netbox/scripts/create-switch/create-switch.py')
-rw-r--r--tools/netbox/scripts/create-switch/create-switch.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/netbox/scripts/create-switch/create-switch.py b/tools/netbox/scripts/create-switch/create-switch.py
index 3fad7c3..7537847 100644
--- a/tools/netbox/scripts/create-switch/create-switch.py
+++ b/tools/netbox/scripts/create-switch/create-switch.py
@@ -446,6 +446,7 @@ class CreateSwitch(Script):
try:
uplink_tag = Tag.objects.get(slug=f"{num_uplinks}-uplinks")
switch.tags.add(uplink_tag)
+ self.log_info(f"Added tag for number of uplinks if it wasn't present already: {uplink_tag}")
except Tag.DoesNotExist as e:
self.log_error("Failed to find device tag with {num_uplinks} uplinks.")
raise e