Skip to main content

netbox-render

netbox-render

A NetBox plugin I wrote to fix a visibility gap in rack elevations: devices with device bays render as a single opaque block, hiding what's actually installed. This plugin subdivides that block into labeled, color-coded, clickable sections — one per bay.

What it does

Out of the box, NetBox shows a device-bay device as one rectangle with an occupancy count like "3/4". To see what's installed, you have to click into the parent and check the Device Bays tab.

I patched RackElevationSVG._draw_device so each bay gets its own section showing:

  • Bay index (1, 2, 3, ...) sorted by bay name
  • Child device name, or "(empty)"
  • Role color on the front face (rear renders grey, matching stock behavior)
  • Clickable link to the child device page

Devices without bays are untouched.

Before and after

Without plugin With plugin
Stock NetBox elevation With netbox-render
Single opaque block Subdivided with bay labels and role colors

Bay ordering

Bays sort alphabetically by name — there's no numeric position field in NetBox's device bay model. Name them "Slot 01", "Slot 02", etc. for predictable ordering.

Compatibility

NetBox Plugin Status
4.6.x 0.1.5 Tested

Startup checks verify the patched method signature hasn't changed. If it has, the plugin raises a RuntimeError instead of loading.

Installation

pip install netbox-render

Add to configuration.py:

PLUGINS = ['netbox_render']

Restart NetBox:

sudo systemctl restart netbox netbox-rq

For development: pip install -e .

Configuration

One option in PLUGINS_CONFIG:

PLUGINS_CONFIG = {
    'netbox_render': {
        'enable_images': True,  # default: False
    },
}

When enabled, bay sections show the child device type's front/rear image with a text label overlay. Requires restart.

Shelf device guide

See Shelf-devices Guide for a walkthrough on modeling rack shelves using device bays and how this plugin renders them.

Known limitations

  • Bay ordering is name-based, not positional — no way around this without modifying NetBox's data model
  • Images off by default
  • Rear face always renders grey (matches stock NetBox)
  • Both faces show the same bay breakdown
  • No migrations, no DB changes — rendering only
  • Monkeypatch approach: I patch an internal method, so test after every NetBox upgrade

Support

License

Apache-2.0

Metadata

Release files for netbox-render 0.1.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for netbox-render 0.1.5
File Size Uploaded
netbox_render-0.1.5.tar.gz 11.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for netbox-render 0.1.5
File Interpreter ABI Platform
netbox_render-0.1.5-py3-none-any.whl Python 3 none any Details

Total release size: 21.8 kB

Release files / netbox_render-0.1.5.tar.gz

Download URL netbox_render-0.1.5.tar.gz
Size 11.8 kB
Tags Source
SHA-256 checksum
How to use checksums
edde918f55ce213a50bdb63767cdd01e15cc9abf0b7beaefefd0bba7373fa58f
BLAKE2b-256 checksum
How to use checksums
083e18f0226fb50b87e44ea45260ca29084efa19526bc36d8f857bdb6510d614
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 2, 2026.

Transparency log

Release files / netbox_render-0.1.5-py3-none-any.whl

Download URL netbox_render-0.1.5-py3-none-any.whl
Size 10.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d86f17d9c41d8b52ac4c2541c2b3e41f529553688b45a659e660b064872c495b
BLAKE2b-256 checksum
How to use checksums
f533ad091d50a508c8af5f8dc9022bc130a79fcca9ff8ae52541f1de883ca417
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 2, 2026.

Transparency log

Release history Release notifications | RSS feed

0.2.1

2 release files

0.2.0

2 release files

This release

0.1.5 This release

2 release files

0.1.4

2 release files

0.1.3

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page