During some coding work for my day job, I require a way to validate the format (or schema) for some JSON data. If you need a quick refresh, what JSON is and how to work with it in python, take a look at one of my earlier posts about python dictionaries and JSON. As an additional requirement, the validation step should include default data for certain keys that are not found in the original data.
Today I like to describe the target Use Case, functionality and structure of the Network Configuration Generator. Furthermore, I like to describe the Integration and API capabilities that should be implemented. At the end of this post, I discuss some limitations and functionalities that are considered out-of-scope for the first version.
This week, I’ll show you how to integrate custom filters into your Jinja2 templates. The use case from this post is based on the idea of a feature-centric and vendor independent parameter set for the configuration of network devices. We will see how custom filters could be helpful to generate configurations for multiple vendors based on a common parameter set.
This week, I will show you how to build a simple python based configuration generator using the Jinja2 library with CSV and JSON based parameters.