nautobot-app-golden-config
nautobot-app-golden-config copied to clipboard
Near-Live Intended Template Viewer
Environment
- Nautobot version: Latest
- nautobot-golden-config version: latest
Proposed Functionality
A live or at least nearly-live editor of your templates.
Use Case
The ability to quickly troubleshoot your templates, without needing to be in Git
Proposed Design
First Iteration
- File View
- This is a view of the files that are in Jinja template repo
- This should look similar to Github's view of the same thing (see below for example)
- I would be able to select a template and see it
- This would be linked from the menu
Second Iteration
- File View
- I would then be able to select "edit" and get a "j2live" type view in which I can edit the template
- Once done, I could clear out my edit's, if I did not clear out my edits, it would overwrite the next time the specific error
- This would be stored somewhere, that would basically be key = filename, value = new jinja template.
- The somewhere can be a model, redis, or somewhere else haven't thought of yet
- Render View
- Within the Device view, I would be linked to a view of the render view
- Once on the render view, it would run a job that
- Creates a special folder for templates, pull down the latest
- Find each file that was changed and overwrite it in the local filesystem
- Render the config for that device, and return the config. (this is currently found in the UI via "Additional Data" tab -> "Return Data" element.
- As the user, I would need to copy the new templates from the UI, to my local git repo and put in the PR myself
Third Iteration
- Collapse the File and render view as shown in the screen shot
- Note: What is in the template panel that shows while rendering, may not actually matter. What matters is what the job selects as the templates, so as example if you choose a junos device but are showing an ios template, it would not affect anything.
### Tasks
Just a thought, but would caution using "live" in the feature name, might lead someone to think this is deals with the live running device config. Maybe "Template Explorer" or "Config Template Tool" or some such.
Yea, a good note, I would say that all names are not final, I mentioned to Jeff I didn't like a few of the names, but they were more explicit.
I really like this idea. +1
While Googling I found some libraries that might be use to help this along, however they are most likely not following any nautobot models/styling/etc.
https://github.com/cmason3/jinjafx_server https://github.com/cmason3/jinjafx
I really like this idea. +1
While Googling I found some libraries that might be use to help this along, however they are most likely not following any nautobot models/styling/etc.
https://github.com/cmason3/jinjafx_server https://github.com/cmason3/jinjafx
The developer of these two apps is very responsive, and I have requested features in the past, given its ability to be self-hosted for data security purposes, and is python based, I equip our teams with it in the J2 repos for Golden Configuration management by default.
@itdependsnetworks overall this would be an excellent feature, and one that our teams in general have mentioned on several occasions as something they would find useful.
It's high on our list, but still need to dedicate someone to get it done.
Great to hear, thanks for the update @itdependsnetworks and continued focus on cool features to enrich the platform and dev experience