No project description provided
Project description
NetBox plugin for the Kea DHCP server
This plugin allows you to view Kea status, leases and subnets in NetBox. Go directly from a NetBox device/VM to a DHCP lease and back!
Features
- Uses the Kea management API
- View Kea daemon statuses.
- Supports Kea's DHCPv4 and DHCPv6 servers.
- View, delete, export and search for DHCP leases.
- Search for NetBox devices/VMs directly from DHCP leases.
- View DHCP subnets from Kea's configuration.
- REST API and GraphQL support for managing Server objects.
Limitations
-
Due to limitations in the Kea management API, pagination is only supported when searching for leases by subnet. Additionally, you can only go forwards, not backwards.
-
Searching for leases by subnet ID does not support pagination. This may be an expensive operation depending on the subnet size.
-
Kea doesn't provide a way to get a list of subnets without an additional hook library. Thus, this plugin lists subnets using the
config-getcommand. This means that the entire config will be fetched just to get the configured subnets! This may be an expensive operation.
Requirements
- NetBox 4.0, 4.1, 4.2, 4.3, 4.4 or 4.5
- Kea Control Agent
lease_cmdshook library
Compatibility
- This plugin is tested with Kea v2.4.1 with the
memfilelease database. Other versions and lease databases may also work.
Installation
-
Add
netbox-keatolocal_requirements.txt. -
Enable the plugin in
configuration.pyPLUGINS = ["netbox_kea"]
-
Run
./manage.py migrate
Custom Links
You can add custom links to NetBox models to easily search for leases.
Make sure to replace <Kea Server ID> in the link URL with the object ID of your Kea server. To find a server's ID, open the page for the server
and look at the top right corner for netbox_kea.server:<Server ID Here>.
Show DHCP leases for a prefix
Content types: IPAM > Prefix
Link URL: https://netbox.example.com/plugins/kea/servers/<Kea Server ID>/leases{{ object.prefix.version }}/?q={{ object.prefix }}&by=subnet
Show DHCP leases for a device/VM interface (by MAC):
Content types: DCIM > Interface, Virtualization > Interface
Link URL (DHCPv4): https://netbox.example.com/plugins/kea/servers/<Kea Server ID>/leases4/?q={{ object.mac_address }}&by=hw
Link URL (DHCPv6): https://netbox.example.com/plugins/kea/servers/<Kea Server ID>/leases6/?q={{ object.mac_address }}&by=hw
Show DHCP leases for a device/VM (by name):
Content types: DCIM > Device, Virtualization > Virtual Machine
Link URL (DHCPv4): https://netbox.example.com/plugins/kea/servers/<Kea Server ID>/leases4/?q={{ object.name|lower }}&by=hostname
Link URL (DHCPv4): https://netbox.example.com/plugins/kea/servers/<Kea Server ID>/leases6/?q={{ object.name|lower }}&by=hostname
You may also use a custom field by replacing {{ object.name|lower }} with {{ object.cf.<your custom field>|lower }}.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file netbox_kea-1.0.5.tar.gz.
File metadata
- Download URL: netbox_kea-1.0.5.tar.gz
- Upload date:
- Size: 22.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.11.0 {"installer":{"name":"uv","version":"0.11.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7f290992bd040d18a81a8f84d94cffc16075ae0d1b977a3a3a2b048c9ebdaf7b
|
|
| MD5 |
df5aeb08bdb3b01a7ac1be8f3f53a8b1
|
|
| BLAKE2b-256 |
24f10635f2da0ece74682c6098182233b0737ab2cc3bbd9968b6cef4d921d0e6
|
File details
Details for the file netbox_kea-1.0.5-py3-none-any.whl.
File metadata
- Download URL: netbox_kea-1.0.5-py3-none-any.whl
- Upload date:
- Size: 28.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.11.0 {"installer":{"name":"uv","version":"0.11.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
69d0fc29c8554283cffb3fceff8ee0b712ef398844ad534e83d341f0d02d0f7a
|
|
| MD5 |
02e9af2d3b1484054b3206ba677f3a0f
|
|
| BLAKE2b-256 |
2af0f9f0cacad4975fc30fb1ae877daad4b46c2c113212951e1e213a21a73538
|