Tuesday, January 26, 2021

Tool to generate network devices configuration - Template Text Renderer

Hi Folks,

Wrote Template Text Rendered tool to facilitate the process of generating static text files using templates: TTR docs

One of the first use cases that pushed me toward creating this tool was a need to produce configuration files for network devices out of Excel spreadsheets.

TTR is a pluggable framework that can take data from various sources, combine it with templates and produce text output. Additional plugins can be added to support other formats and rendering engines.

It also comes with a collection of Jinja2 templates, not much in it yet, but capability is there.

For examples reference quick start or CLI tool or XLSX loader docs.

Would be glad t hear what you think.

To anticipate the question around why to use excel as an LLD, well, say you need to generate configuration for 50 devices as fast as you can, putting things in CMDB/DCNM of some sort might not make sense, as things might change over time.

What make sense, IMHO, is to use some form of inventory that is human friendly, easy to create, update, share, review, import in CMDB/DCNM later on etc. It happens that such an inventory usually is a some form of spreadsheet or text database like YAML.

TTR can take that inventory and generate configuration files for you, providing that inventory data structured in a way compatible with TTR in the first place.



No comments:

Post a Comment