From b2f7f05cbe8081eb1e573ece8824af25adf93902 Mon Sep 17 00:00:00 2001 From: Arthur Date: Fri, 17 Feb 2023 08:37:39 -0800 Subject: [PATCH] 10520 re-add config parameters --- netbox/netbox/config/parameters.py | 33 ++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/netbox/netbox/config/parameters.py b/netbox/netbox/config/parameters.py index 06b5343be..8efb0a033 100644 --- a/netbox/netbox/config/parameters.py +++ b/netbox/netbox/config/parameters.py @@ -149,6 +149,39 @@ PARAMS = ( }, ), + # NAPALM + ConfigParam( + name='NAPALM_USERNAME', + label=_('NAPALM username'), + default='', + description=_("Username to use when connecting to devices via NAPALM") + ), + ConfigParam( + name='NAPALM_PASSWORD', + label=_('NAPALM password'), + default='', + description=_("Password to use when connecting to devices via NAPALM") + ), + ConfigParam( + name='NAPALM_TIMEOUT', + label=_('NAPALM timeout'), + default=30, + description=_("NAPALM connection timeout (in seconds)"), + field=forms.IntegerField + ), + ConfigParam( + name='NAPALM_ARGS', + label=_('NAPALM arguments'), + default={}, + description=_("Additional arguments to pass when invoking a NAPALM driver (as JSON data)"), + field=forms.JSONField, + field_kwargs={ + 'widget': forms.Textarea( + attrs={'class': 'vLargeTextField'} + ), + }, + ), + # User preferences ConfigParam( name='DEFAULT_USER_PREFERENCES',