Examples from Cisco Live EMEA 2023
This script should be saved to /etc/netbox/scripts. This path can be changed by setting SCRIPTS_ROOT in NetBox's configuration.
- Creates a Netbox Form - collects input data in netbox (site code, name, number of switches)
- Creates new site
- Selects next available IP prefix, reserves it for the site
- DNS reservations for router and switches
- Creates rack
- Creates devices
- Assigns IPs to interfaces
- Adds devices to NSO and fetches their ssh host keys
This script we can run from the environment, where NSO is running
- Gets the information on site subnet from Netbox,
- Reserves new pool in Netbox for site DHCP server
- Configures router as DHCP server