Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sapcc/netbox-device-groups
A netbox plugin for managing multiple device group types and device groups, by site.
https://github.com/sapcc/netbox-device-groups
Last synced: 11 days ago
JSON representation
A netbox plugin for managing multiple device group types and device groups, by site.
- Host: GitHub
- URL: https://github.com/sapcc/netbox-device-groups
- Owner: sapcc
- License: apache-2.0
- Created: 2023-09-19T12:54:45.000Z (about 1 year ago)
- Default Branch: develop
- Last Pushed: 2024-05-23T09:00:21.000Z (6 months ago)
- Last Synced: 2024-05-23T10:24:03.063Z (6 months ago)
- Language: Python
- Homepage: https://sapcc.github.io/netbox-device-groups/
- Size: 1.38 MB
- Stars: 1
- Watchers: 30
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
A netbox plugin for managing multiple device group types by site
## Installing the Plugin in Netbox
### Prerequisites
- The plugin is compatible with Netbox 3.5.0 and higher.
- Databases supported: PostgreSQL
- Python supported : Python3 >= 3.10### Install Guide
> NOTE: Plugins can be installed manually or using Python's `pip`. See the [netbox documentation](https://docs.netbox.dev/en/stable/plugins/) for more details. The pip package name for this plugin is [`netbox-device-groups`](https://pypi.org/project/netbox-device-groups/).
The plugin is available as a Python package via PyPI and can be installed with `pip`:
```shell
pip install netbox-device-groups
```To ensure the device group plugin is automatically re-installed during future upgrades, create a file named `local_requirements.txt` (if not already existing) in the Netbox root directory (alongside `requirements.txt`) and list the `netbox_device_groups` package:
```shell
echo netbox-device-groups >> local_requirements.txt
```Once installed, the plugin needs to be enabled in your Netbox configuration. The following block of code below shows the additional configuration required to be added to your `$NETBOX_ROOT/netbox/configuration.py` file:
- Append `"netbox_device_groups"` to the `PLUGINS` list.
- Append the `"netbox_device_groups"` dictionary to the `PLUGINS_CONFIG` dictionary and override any defaults.```python
PLUGINS = [
"netbox_device_groups",
]
```## Post Install Steps
Once the Netbox configuration is updated, run the post install steps from the _Netbox Home_ to run migrations and clear any cache:
```shell
# Apply any database migrations
python3 netbox/manage.py migrate
# Trace any missing cable paths (not typically needed)
python3 netbox/manage.py trace_paths --no-input
# Collect static files
python3 netbox/manage.py collectstatic --no-input
# Delete any stale content types
python3 netbox/manage.py remove_stale_contenttypes --no-input
# Rebuild the search cache (lazily)
python3 netbox/manage.py reindex --lazy
# Delete any expired user sessions
python3 netbox/manage.py clearsessions
# Clear the cache
python3 netbox/manage.py clearcache
```Then restart the Netbox services:
```shell
sudo systemctl restart netbox netbox-rq
```