Open whitej6 opened 10 months ago
@mzbroch how the view is done here is not how it will be implemented. Opened the PR to highlight the ensure git part. I had this working already so it was easy to add the line below for Ken to see what I meant on every request we do ensure git.
@mzbroch how the view is done here is not how it will be implemented. Opened the PR to highlight the ensure git part. I had this working already so it was easy to add the line below for Ken to see what I meant on every request we do ensure git.
It would be nice to see some screenshots!
What I am saying, is following is the ideal template structure we produce :
However, the cisco_ios.j2
is just a dispatching template (GC would render this one for Cisco).
This one support multiple template versions, network design revisions and device role based dispatching :
{% set root_path = './cisco_ios/' ~ design_rev %}
{% set include_path = root_path ~ '/' ~ role %}
{% include root_path ~ '/' ~ role ~ '_main.j2' %}
My perspective, is that as a User, I would like to see the config elements instead of dispatching template - perhaps this is possible using jinja internals ? Ideally this should show aggregated aaa+interfaces+ntp+dns+...+...
I do realise, looking at it from feature perspective proposed implementation works. I think, most of users will have a structure and a set of templates. Per vendor, per role, per device type etc. At the top of this structure, there are some conditional and logic for nesting/structuring the templates. As we increase template/configuration coverage over the time, complexity of the structure grows.
Nothing to do with the purpose of this PR and no work has been done to visualize what Ken described in the issue. This was solely to showcase the option for ensuring the files exist locally on web hosts since the repo sync job only applies to the workers.