Skip to main content

Plugin that shows NetBox devices and modules in tables.

Project description

Inventory Viewer

Inventory Viewer is a plugin for NetBox that displays modules (NetBox dcim.Module objects) in tables, grouped by their module types. This plugin is especially helpful if you need a quick overview of installed modules and their properties (like serial numbers, asset tags, location, cable connections, notes, and custom fields).


Features

  • Grouped Module Tables: Displays modules organized by module type on a dedicated page.
  • Custom Fields Integration: Shows data from custom fields (e.g., “rok_zavedeni” or “merici_bod”) if present.
  • Cable Connections: Prints out cable termination endpoints for each module, indicating how they’re connected.
  • Site & Location Overviews: For each module, provides an at-a-glance view of where it resides (site, location, device).
  • Easy Navigation: Integrated into NetBox’s main menu (under “Plugins”) for fast access to the module tables.

Requirements

This plugin has been developed and tested on:

  • NetBox: version 4.1.6
  • Python: version 3.10.12 or higher

While it may work on later NetBox versions, these are the ones used during development and testing. If you encounter any incompatibility, please open an issue.


Installation

Step 1: Install using pip

pip install inventory_viewer

Step 2: Add the plugin into PLUGINS array in configuration.py

PLUGINS = [
    'inventory_viewer',
    # Other plugins...
]

Step 3: Run netbox(for example)

python manage.py runserver

Usage

View Modules

  1. In the NetBox main menu, find “Inventory Viewer” under the Plugins section.

  2. The plugin automatically lists all modules in NetBox, grouped by module type (e.g., Silicom N5010, Silicom N6010, etc.).

  3. Each module’s entry shows:

    • Serial (SN)
    • Custom Fields like “rok_zavedeni,” “merici_bod,” etc.
    • Asset Tag (Ev. č.)
    • Location (site, location, device)
    • Cable Connections (includes connected interfaces or ports and where they lead)
    • Notes (comments field)

Cable Connections

When a module is connected via front/rear ports or interfaces, the plugin displays a short summary describing each cable’s endpoints, for example:

DeviceA/Eth1 <-> DeviceB/Eth3

Custom Fields

If your NetBox instance has custom fields like “rok_zavedeni” or “merici_bod” defined for the dcim.Module model, those values automatically appear as columns in the module table.

Project Structure

inventory_viewer/
├── views.py               # Transfer and linking logic
├── templates/             # HTML templates
├── urls.py                # Plugin URLs
├── navigation.py          # Plugin menu entries
└── tables.py/             # Custom table

Changelog

v1.0

  • Initial release: Displays modules grouped by module type in tables
  • Shows cable connections, device location, and custom fields
  • Integrates directly into NetBox’s plugin menu

Notes

  • Non-Intrusive: This plugin does not override NetBox’s core behavior or templates. It only adds new pages and logic within the plugin framework.

  • Custom Fields: If you have not defined the custom fields (“rok_zavedeni”/“merici_bod”), you have to define them in your netbox instance, i tried to make this via python script but it didn't work. I defined rok_zavedeni as integer and merici_bod as text.

  • Cable Data: The plugin relies on standard dcim.Module relationships (frontports, rearports, interfaces). If a module’s device or ports are not set properly, the cable connection info may appear incomplete.

Author

Viktor Kubec
BUT FIT Brno student
MIT License
GitHub: vubeckubec/inventory_viewer

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

inventory_viewer-1.0.tar.gz (8.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

inventory_viewer-1.0-py3-none-any.whl (8.6 kB view details)

Uploaded Python 3

File details

Details for the file inventory_viewer-1.0.tar.gz.

File metadata

  • Download URL: inventory_viewer-1.0.tar.gz
  • Upload date:
  • Size: 8.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.10.12

File hashes

Hashes for inventory_viewer-1.0.tar.gz
Algorithm Hash digest
SHA256 89207318219aa4b6b8953e1c61aa9b268fb04de7ed9fb5cb0b0d6e2aec5c58e7
MD5 8617c688c50454df772fde5d1a07f9d4
BLAKE2b-256 0f3bb5aad6f79753b2b2bcf48437c69e81efb9d9724f2aef4e142f41f8acbe57

See more details on using hashes here.

File details

Details for the file inventory_viewer-1.0-py3-none-any.whl.

File metadata

  • Download URL: inventory_viewer-1.0-py3-none-any.whl
  • Upload date:
  • Size: 8.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.10.12

File hashes

Hashes for inventory_viewer-1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e36210a10258a15a42d2486f5ba71d648c6fe26da876f33c30360da4a87ec6bb
MD5 7f69a2df315406c27f2eba8e127a5bb2
BLAKE2b-256 4ad66bd6150f3ce575eac5409c0aebae1c16aeb7de165f7f306b1b694873e576

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page