feat(settings): Add NETBOX_COPILOT_URL configuration and URL validation #62

Closed
opened 2026-04-05 16:21:25 +02:00 by MrUnknownDE · 0 comments
Owner

Originally created by @MyEcoria on 3/27/2026

This pull request updates the configuration for the NetBox Copilot integration to allow dynamic configuration of the Copilot URL and to enforce validation for its format. The main change is to make the Copilot URL configurable via the configuration object and to ensure that any provided URL is valid.

Configuration improvements:

  • Updated the assignment of NETBOX_COPILOT_URL in settings.py to use the value from configuration.NETBOX_COPILOT_URL if present, falling back to the default URL otherwise.
  • Added validation for NETBOX_COPILOT_URL using Django's URLValidator, raising an ImproperlyConfigured exception if the URL is invalid.
*Originally created by @MyEcoria on 3/27/2026* This pull request updates the configuration for the NetBox Copilot integration to allow dynamic configuration of the Copilot URL and to enforce validation for its format. The main change is to make the Copilot URL configurable via the `configuration` object and to ensure that any provided URL is valid. Configuration improvements: * Updated the assignment of `NETBOX_COPILOT_URL` in `settings.py` to use the value from `configuration.NETBOX_COPILOT_URL` if present, falling back to the default URL otherwise. * Added validation for `NETBOX_COPILOT_URL` using Django's `URLValidator`, raising an `ImproperlyConfigured` exception if the URL is invalid.
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/netbox#62