In this project, I explore a potential method for allowing installation crews to generate their own configurations at will. The goal is to remove the technical nature of preparing CPE equipment, device management software, and monitoring services.
This project was started and mostly finished before Netbox Plugins. I will release the codebase once I have this project wrapped up in a plugin. ETA: 8/1/2021
Example
There has been a growing problem regarding CPE availability now that office staff work from home. The installer teams must request the list of CPEs well in advance to give our technicians ample time to schedule in office visits. The procedure looks like this.
- An install team schedules fiber optic installs for x number of businesses a week in advance. The list of businesses is given to the office staff.
- A technician schedules a day to drive into the office and configure switches
- A technician gathers information regarding each individual circuit
- Management network
- Available IP, vlan, firewall
- POP
- Uplink switch
- Available uplink port
- Identification
- Name, location, package
- Demarcation
- Mounting options
- Based on the above variables the technician will:
- Decide which Mikrotik will be deployed
- Apply a “hot-n-ready” configuration
- Change circuit specific settings
- Test the device
- Add device central monitoring server
- Add device into device management server
- Hand off the device
- Configure the uplink switch port for circuit specific information
- Update device management server
The procedure is not complex or all that difficult in general and has a well-defined SOP. This is a great example of a process that can be automated.
There are many different deployments we could switch to, we could use a media converter instead of a managed switch, we could use some sort of automated configuration protocol like TR-69, we could use a proprietary vendor solution for ZTP, or we could change our deployment processes to facilitate a different procedure all together. Given our existing environment, I propose an additional option.
What if we could give the install crews the power to generate configurations with a simple interface without changing the network, the physical install processes, or the equipment? The process could look something like this:
- An install team schedules fiber optic installs for x number of businesses a week in advance
- The install team visits a webpage and enters in required fields
- The webpage updates device management software, monitoring software, builds a configuration based on the fields entered and configures the uplink switch
- The webpage provides the configuration, uplink switch port, and confirmation the device has been documented and monitored
We don’t want or need the installers to know how to configure a Mikrotik, they only need to know how to upload a configuration which is a reasonable request.
To accomplish these goals, we can utilize the following:
- Netbox
- Ansible
- Zabbix
- Python
*This primer won’t detail how any of these services work, but instead how they may be utilized to accomplish the task above.
Phase 1: An intuitive interface that will document our CPE
Phase 2: Document device with specific organizational parameters
Phase 3: Configuring Ansible for Netbox
Phase 4: Writing our Ansible playbook
Phase 5: Writing our Jinja template
Phase 6: Checkpoint. Let's recap and test what we have done so far
Phase 7: Creating an endpoint for the webhooks
Phase 8: Create the Netbox webhook
Phase 9: Uploading configurations to Gitlab
Phase 10: Add custom button to Netbox for Git integration