NoOne-dev / netbox_topology

patch to apply to a netbox installation to add beautiful topology view to sites

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

netbox_topology

Note: For Netbox v2.8.0+, please consider using nextbox-ui-plugin or netbox-topology-views instead.

Patch to apply to a netbox installation to add beautiful topology view to sites

Updated by mylivingweb to use /api/dcim/cables/ endpoint instead of /api/dcim/interface-connections/

Additional tweaks, such as cable-type changing selection colors added by NoOne-dev

Once installed your individual site's pages should look like this:

Screenshot

This module allows to create and delete connections between interfaces via control panel:

Screenshot control panel

INSTALL:

  1. clone git repo
git clone https://github.com/NoOne-dev/netbox_topology.git
  1. run install.sh, sudo might be required to get access to netbox installation directory:
cd netbox_topology
sudo ./install.sh
  1. restart netbox via supervisord or apache/nginx depending on your installation
sudo supervisorctl restart netbox
sudo service apache2 restart
  1. open django admin web-interface and create a custom text field named "coordinates" under dcim->device model

Screenshot django setup

  1. modify $NETBOXPATH/netbox/static/js/topology_config.json to include your list on roles to hide from the topology view. You will need to add new list of cables to shown under shown_cables. Constants are defined here
CABLE_TYPE_CAT3 = 1300
CABLE_TYPE_CAT5 = 1500
CABLE_TYPE_CAT5E = 1510
CABLE_TYPE_CAT6 = 1600
CABLE_TYPE_CAT6A = 1610
CABLE_TYPE_CAT7 = 1700
CABLE_TYPE_MMF_OM1 = 3010
CABLE_TYPE_MMF_OM2 = 3020
CABLE_TYPE_MMF_OM3 = 3030
CABLE_TYPE_MMF_OM4 = 3040
CABLE_TYPE_SMF = 3500
CABLE_TYPE_POWER = 5000

please note that the list should include SLUGs for roles, not names and number for the cables to be shown. please check that json is valid.

  1. let me know if there are any issues - https://github.com/NoOne-dev/netbox_topology/pulls

UNINSTALL:

sudo ./uninstall.sh

OR if your installation is GIT based (Option 2 from Netbox installation guide):

cd /opt/netbox
git checkout .

About

patch to apply to a netbox installation to add beautiful topology view to sites

License:Apache License 2.0


Languages

Language:JavaScript 88.9%Language:Shell 11.1%